Closed davidtheclark closed 7 years ago
Thought about this some more and I'm changing my mind. I don't think jsxtreme-html would fit the use case, actually. Here's what's needed:
There may actually be a much simpler way to address this need. I'm going to try this:
dangerouslySetInnerHTML
to render it onto the page.Started work on this and realized how much code it will add (and need for examples and documentation and tests). I'm wondering if this use case will be common enough to justify that. Because the simpler alternative exists to create a JS page and use the raw-loader to import an HTML file — the only downside being that you create two files instead of one.
That's totally reasonable, the only other cases I know of that might need something like this are Mapbox.js (if its docs ever get converted to batfish) or something like http://turfjs.org/docs/.
I'll take a look at the raw-loader approach.
Ok 👍 Closing this issue in favor of https://github.com/mapbox/batfish/pull/195, which introduces ignoreWithinPagesDirectory
so you can colocate HTML files with the pages that import them.
@jfirebaugh needs some jsxtreme-html, for all the same reasons somebody might want jsxtreme-markdown plus wanting to write the source code in HTML, instead of Markdown.
The code for jsxtreme-html would be only slightly different from that for jsxtreme-markdown — I wonder how much they could share. So I think we could accomplish this without too much fuss.