Package: checklist-seo
Check list SEOFeaturesKeyword repartitionLength contentCheck title article lengthUrl is optimizedNumber internal LinksInstallationPypipip install checklist-seoInstalling the application in DjangoTo use this application, you need first to add it to your config file.In your config file (ex: settings.py):# Application definitionINSTALLED_APPS = [
...
'seo'
...
]SEO PannelTo setup the keyword for SEO, you need to add a special SEO Pannel that will appear in your page creation in wagtail admin.The module contains a model in models/SeoPage, the model need to be used as a base for your page models.Example of your model:classHomePage(SeoPage):date=models.DateField("Post date")intro=models.CharField(max_length=250)delay=models.IntegerField(default=0,validators=[MaxValueValidator(99),MinValueValidator(0)])body=StreamField([('text',RichTextBlock(blank=True,features=['h2','h3','h4','bold','italic','link','code','ol','ul','hr','document-link','image','embed','superscript','subscript','strikethrough','blockquote'])),('rawHtml',RawHTMLBlock(blank=True)),],blank=True)images_keyword=models.CharField(max_length=250,blank=True)selected_image=models.ForeignKey('wagtailimages.Image',null=True,blank=True,on_delete=models.SET_NULL,related_name='+')<span class="n">keep_slug</span> <span class="o">=</span> <span class="n">models</span><span class="o">.</span><span class="n">BooleanField</span><span class="p">(</span>
    <span class="n">verbose_name</span><span class="o">=</span><span class="p">(</span><span class="s1">&#39;Keep current slug&#39;</span><span class="p">),</span>
    <span class="n">default</span><span class="o">=</span><span class="kc">False</span><span class="p">,</span>
    <span class="n">help_text</span><span class="o">=</span><span class="p">(</span><span class="s2">&quot;Keep current slug or save to generate a new slug.&quot;</span><span class="p">)</span>
<span class="p">)</span>

<span class="k">def</span> <span class="nf">_get_autogenerated_slug</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">base_slug</span><span class="p">):</span>
    <span class="sd">&quot;&quot;&quot;Redefinition of wagtail&#39;s _get_autogenerated_slug so you can use your own slug generator.&quot;&quot;&quot;</span>
    <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">slug</span>

<span class="n">search_fields</span> <span class="o">=</span> <span class="n">Page</span><span class="o">.</span><span class="n">search_fields</span> <span class="o">+</span> <span class="p">[</span>
    <span class="n">index</span><span class="o">.</span><span class="n">SearchField</span><span class="p">(</span><span class="s1">&#39;intro&#39;</span><span class="p">),</span>
<span class="p">]</span>

<span class="n">content_panels</span> <span class="o">=</span> <span class="n">Page</span><span class="o">.</span><span class="n">content_panels</span> <span class="o">+</span> <span class="p">[</span>
    <span class="n">MultiFieldPanel</span><span class="p">([</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;date&#39;</span><span class="p">),</span>
        <span class="n">FieldRowPanel</span><span class="p">([</span>
            <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;delay&#39;</span><span class="p">),</span>
        <span class="p">]),</span>
    <span class="p">],</span> <span class="n">heading</span><span class="o">=</span><span class="s2">&quot;Blog information&quot;</span><span class="p">),</span>
    <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;intro&#39;</span><span class="p">),</span>
    <span class="n">StreamFieldPanel</span><span class="p">(</span><span class="s1">&#39;body&#39;</span><span class="p">),</span>
    <span class="n">FieldRowPanel</span><span class="p">([</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;images_keyword&#39;</span><span class="p">),</span>
    <span class="p">],</span> <span class="n">heading</span><span class="o">=</span><span class="s2">&quot;Images&quot;</span><span class="p">),</span>
    <span class="n">ImageChooserPanel</span><span class="p">(</span><span class="n">field_name</span><span class="o">=</span><span class="s2">&quot;selected_image&quot;</span><span class="p">,</span> <span class="n">heading</span><span class="o">=</span><span class="s2">&quot;Image sélectionnée&quot;</span><span class="p">),</span>
<span class="p">]</span>

<span class="n">promote_panels</span> <span class="o">=</span> <span class="p">[</span>
    <span class="n">MultiFieldPanel</span><span class="p">([</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;slug&#39;</span><span class="p">),</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;keep_slug&#39;</span><span class="p">),</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;seo_title&#39;</span><span class="p">),</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;show_in_menus&#39;</span><span class="p">),</span>
        <span class="n">FieldPanel</span><span class="p">(</span><span class="s1">&#39;search_description&#39;</span><span class="p">),</span>
    <span class="p">],</span> <span class="n">heading</span><span class="o">=</span><span class="s2">&quot;Common Page Configuration&quot;</span><span class="p">),</span>
<span class="p">]</span>

<span class="n">edit_handler</span> <span class="o">=</span> <span class="n">TabbedInterface</span><span class="p">([</span>
    <span class="n">ObjectList</span><span class="p">(</span><span class="n">content_panels</span><span class="p">,</span> <span class="n">heading</span><span class="o">=</span><span class="s1">&#39;Content&#39;</span><span class="p">),</span>
    <span class="n">ObjectList</span><span class="p">(</span><span class="n">promote_panels</span><span class="p">,</span> <span class="n">heading</span><span class="o">=</span><span class="s2">&quot;Promote&quot;</span><span class="p">),</span>
    <span class="n">SeoPage</span><span class="o">.</span><span class="n">seo_object_list</span><span class="p">,</span>
    <span class="n">ObjectList</span><span class="p">(</span><span class="n">Page</span><span class="o">.</span><span class="n">settings_panels</span><span class="p">,</span> <span class="n">heading</span><span class="o">=</span><span class="s1">&#39;Settings&#39;</span><span class="p">)</span>
<span class="p">])</span>RoutingIn your routing projet fileurls.pyfromdjango.conf.urlsimporturlfromdjango.urlsimportincludeurlpatterns=[...url(r'^seo/',include('seo.urls'),name='seo'),]StaticTo get the CSS / JS / Image file from this app to your projetpython manage.py collectstaticDB MigrationNow you can detect the changepython manage.py makemigrationsAnd apply it on DBpython manage.py migrationTestpytest