DEV Community


Discussion on: How I accidentally wrote an awesome HTML Preprocessor

nektro profile image
Meghan (she/her) Author

Importing the code from bs4-accordion.html just once, <bs4-accordion> becomes a tag available anywhere in the document. The slightly monotonous init JS is because of the specificity of Bootstrap syntax but with the Custom Element it sets all that up for you.

Thread Thread
morgboer profile image
Riaan Pietersen

Sounds ideal then :)

Have you looked at riot.js? Perhaps some knowledge to glean from there too.

Are you happy with it?