Closed jessestorbeck closed 10 months ago
This now includes an additional feature. During prep
, static assets used inside the jsPsych timeline in experiment.js
are copied from the experiment's web page/src/assets/timeline
folder to the site's pushkin/front-end/public/experiments/[experiment_name]
folder.
pushkin/front-end/public
can be referenced at runtime using the environment variable process.env.PUBLIC_URL
.
This PR includes two new features:
prep
, any plugins which are imported in experiment.js but haven't been added as dependencies getyarn add
-ed.install experiment
, users have the option of importing a jsPsych experiment.html if they choose the basic template. This will automatically identify the plugins they need and make a new experiment.js with their timeline and the required import statements. These plugins get added as dependencies later by the feature above.I'm making this a draft, since (1) I'd like some help testing it and (2) we can wait to merge these changes until we finish with the other changes to
prep
re: jsPsych timeline assets.