Closed BlakeTurner closed 7 years ago
Hey Blake! I'm glad you like exerslide 😃
One thing you can do is use the atRequireExpansion
transform in webpack.config.js
(example) and in the slide do
---
layout_data:
assertion: @require('!!raw!path/to/file/')
---
That should include the content of path/to/file/
as a string (I believe I have done this before, but you should try and see whether it really works), just as if you had written the content of the file in the slide.
Is that what you are looking for?
That is awesome. Thanks!
I assume this resolved then?
First off: this is a really interesting project. Great work!
Re: the JavaScriptExercise layout
I'm wondering if it would be possible for the slide to include an external JS file instead of requiring that assertions be written in the front matter. Maybe a specific path/naming convention would make this easier to achieve?
The use-case is that we'd like to be able to write the assertions and also optionally fire off analytics events on success/fail. That way we can track the success of any given lesson.
Thanks!