Wikiki / bulma-steps

Bulma's extension to manage steps
MIT License
96 stars 44 forks source link

Module build failed: Syntax Error #20

Open YacineGameDev opened 6 years ago

YacineGameDev commented 6 years ago

I'm trying to integrate bulma-steps to my project so I installed the extensions via npm with npm install --save bulma-steps then I have included bulma steps to my main css file styles.css with @import 'bulma'; @import '~bulma-steps'; And when I try to build my project I have this error :

capture

Wikiki commented 6 years ago

Be carefull the default file for import is the sass one. Try specifying .min.css in your import rule (I don't know if you hahe to specify the full path)

YacineGameDev commented 6 years ago

yes this worked thanks, I have another question do we have to include the javascript file in index.html for the steps navigation to work? Right now, clicking on next doesn't have the correct behavior.

Wikiki commented 6 years ago

Yes you have to include the JavaScript part too

YacineGameDev commented 6 years ago

that's waht I'm trying to do for the past 45 minutes, I have added <script type="text/javascript" src="/node_modules/bulma-extensions/bulma-steps/dist/js/bulma-steps.min.js"></script> to my index.html but when I did so I'm getting this error in the console :

Uncaught SyntaxError: Unexpected token <

Wikiki commented 6 years ago

Weird. Try with non minified version to see if you still having the issue ?

YacineGameDev commented 6 years ago

yes same :confused:

YacineGameDev commented 6 years ago

I managed to fix the issue however the steps still not work but now I don't have anymore the previous error. I followed this stackoverflow post https://stackoverflow.com/questions/27464168/how-to-include-scripts-located-inside-the-node-modules-folder I don't know what's exactly the problem

Wikiki commented 6 years ago

Hi,

if you're using webpack please have a look on my gulpfile.js configuration file (in the repository)

B-PRAVEEN commented 5 years ago

@import 'node_modules/bulma-steps/dist/css/bulma-steps.sass';

Add this in styles.scss after bulma.