steevepay / riotjs-vite-setup

Minimum setup to start a RiotJS project with ViteJS
1 stars 0 forks source link

Trying to add Pug #1

Open wgehner opened 4 months ago

wgehner commented 4 months ago

Hi,

I really appreciated your tutorial on this. Trying make this work with a riot component written in pug, so far without success.

More at https://github.com/wgehner/riot-vite-pug

Any thoughts?

Wolfgang

steevepay commented 4 months ago

Hello @wgehner and thanks for your support.

I never wrote components with Pug, I would try to install vite-plugin-pug and define it in the vite.config.mjs, under the plugins attribute, before the Riot plugin.

As an alternative solution, Riot support with a "pre-processors" mentioned on the following riot section: https://riot.js.org/compiler/#pre-processors but it seems working only if we use the Riot/CLI.

Let me know if the vite-plugin-pug works.