riotjs-loader icon indicating copy to clipboard operation
riotjs-loader copied to clipboard

setup coffescript html parsing

Open blahutka opened this issue 9 years ago • 1 comments

Hi @esnunes do you know how to tweak this in webpack config? This works when I add this to riotjs-loader https://github.com/muut/riotjs/issues/751

riot.parsers.js.coffeescript = riot.parsers.js.coffee;
return riot.compile(content, options);

I need to parse html with this type

<script type="text/coffeescript">
    @test = 'riotjs awesome'
</script>

blahutka avatar May 20 '15 15:05 blahutka

Try adding query: { type: "coffee" } to your definition.

For example:

preLoaders: [
    { test: /\.tag/, loader: "riotjs", query: { type: "coffee" } }
]

chaucerbao avatar Jul 10 '15 20:07 chaucerbao