I'm getting this error when I was trying to use this in reactjs
pratik9722 opened this issue · comments
./src/tourguidejs/tourguide.esm.js
Line 8:172: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:541: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:3717: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:4877: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:5761: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:7802: Expected an assignment or function call and instead saw an expression no-unused-expressions
Try to import Tourguide module like in new version of readme
I was following this https://www.npmjs.com/package/tourguidejs
and I did
import "./node_modules/tourguide/tourguide.css";
import Tourguide from "./node_modules/tourguide/tourguide.esm.js";
but it gives me these errors
./src/tourguidejs/tourguide.esm.js
Line 8:172: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:541: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:3717: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:4877: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:5761: Expected an assignment or function call and instead saw an expression no-unused-expressions
Line 8:7802: Expected an assignment or function call and instead saw an expression no-unused-expressions
after that I did this
import Tourguide from 'tourguidejs';
import './tourguide.css';
(& of course, you have to do this npm i tourguidejs)
and it's working! thank you for making this script.
@PhilippeTrounev
This issue should be closed. he solves the problem.
Note: if you have still had errors, try these solutions.
add .eslintignore to the root directory
file: .eslintignore
...
# root node_modules
node_modules
# nested node_modules
**/node_modules
...