Mɔfiame Si Wowɔ Ɖe Ɖoɖo Nu

Mina míatsɔ demo site i18n-demo.github.io

Fail siwo sɔ kple teƒe siwo woɖo xexlẽdzesi na le nɔnɔmetata si le etame lae nye esiawo:

  1. Miame .i18n/htm/t1.pug
  2. Nuɖusi .i18n/htm/t2.pug

pug nye template gbegbɔgblɔ si naa HTML 's.

➔ Zi afisia dzi be nàsrɔ̃ gbeŋutise si le pug

Wozãa nɔnɔme ka ${I18N.sponsor} le faɛl la me tsɔ wɔa dukɔwo dome wɔwɔ, eye woatsɔ nuŋɔŋlɔ si sɔ le i18n.yml

Fail .i18n/htm/topbar.css :

[!WARN] Mègaŋlɔ css kple js ɖe pug me o , ne menye nenema o la, vodada aɖe anɔ anyi.

Nyatakakadzraɖoƒe Ƒe Akpa Aɖewo

js mateŋu aŋlɔ ɖe pug Ne ehiã be woawɔ nu aduadu la, woateŋu akpɔe to web ƒe akpa aɖe wɔwɔ me.

Kpeɖodzinuwo ateŋu aɖe nyatakakadzraɖoƒe ƒe akpa aɖe gɔme le md/.i18n/htm/index.js me eye emegbe woazã akpa si le foot.pug me.

Ele bɔbɔe be woawɔ web ƒe akpa aɖewo, abe custom <x-img> .

customElements.define(
  'x-img',
  class extends HTMLElement {
    constructor() {
      super();
      var img = document.createElement('img');
      img.src = '//p.3ti.site/i18n.svg';
      img.style = "height:99px;width:99px;";
      this.append(img);
    }
  }
)

Fifia la, woyɔ x/i-h.js le md/.i18n/htm/index.js me, si nye nyatakakadzraɖoƒe ƒe akpa si wozãna hena dukɔwo dome mɔzɔzɔ kple afɔti me nyawo ƒe nuŋɔŋlɔ si wowɔ ɖe ɖoɖo nu Kpɔ dzɔtsoƒe ƒe kɔpi 18x/src/i-h.js