-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Following the current quick start in the readme I get a plugin svelte) ParseError: Identifier is expected #53
Comments
Have you installed and configured sass? |
Thanks for responding. I get this when I run node-sass -v. Does that seem right? Now using node v13.5.0 (npm v6.13.4) Another piece of information I can get git@github.com:Kiho/smelte-demo.git to run fine. The setup seems quite different though. |
Personally, I use dart-sass
Also my rollup_start_dev.js :
You should proceed with caution: add code block by block until you get rid of errors and you get the expected result
Good luck! |
The same issue i have! |
Same issue! |
Also add these to the
Should look something like this:
|
Hi, there !
here's my rollup config |
Any chance to get correct, complete and properly tested Installation guide for beginners? |
@zoulja |
@abbychau I think the issue is that with a fresh svelte setup, there is no sass support: https://github.com/sveltejs/template/blob/master/rollup.config.js yet by the looks of the above comments, sass is a requirement. It would be good for the setup guide was going from the above rollup config to a working svelma rollout config |
The install leads to many errors with
import svelte from 'rollup-plugin-svelte';
import commonjs from '@rollup/plugin-commonjs';
import resolve from '@rollup/plugin-node-resolve';
import livereload from 'rollup-plugin-livereload';
import { terser } from 'rollup-plugin-terser';
//import css from 'rollup-plugin-css-only';
import autoPreprocess from 'svelte-preprocess';
import postcss from 'rollup-plugin-postcss'
import preprocess from 'svelte-preprocess'
const production = !process.env.ROLLUP_WATCH;
function serve() {
let server;
function toExit() {
if (server) server.kill(0);
}
return {
writeBundle() {
if (server) return;
server = require('child_process').spawn('npm', ['run', 'start', '--', '--dev'], {
stdio: ['ignore', 'inherit', 'inherit'],
shell: true
});
process.on('SIGTERM', toExit);
process.on('exit', toExit);
}
};
}
export default {
input: 'src/main.js',
output: {
sourcemap: true,
format: 'iife',
name: 'app',
file: 'public/build/bundle.js'
},
plugins: [
svelte({
compilerOptions: {
// enable run-time checks when not in production
dev: !production
},
preprocess: autoPreprocess(),
emitCss: true,
}),
postcss({
extract: true,
minimize: true,
use: [
[
"sass",
{
includePaths: ["./node_modules", "./node_modules/bulma", "./src"],
},
],
],
}),
//css({ output: 'bundle.css' }),
resolve({
browser: true,
dedupe: ['svelte']
}),
commonjs(),
!production && serve(),
!production && livereload('public'),
production && terser()
],
watch: {
clearScreen: false
}
}; |
This is when I try to
This is the error:
This is my enviroment:
Now using node v13.5.0 (npm v6.13.4)
The text was updated successfully, but these errors were encountered: