Skip to content

Get svelte-loader working with v3 alpha #73

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

Merged
merged 2 commits into from
Dec 30, 2018

Conversation

malkomalko
Copy link
Contributor

@malkomalko malkomalko commented Dec 30, 2018

This makes some small changes to get svelte-loader working with the current v3 alpha branch.

Todo

  • Fix failing tests

@Rich-Harris
Copy link
Member

thanks! looks like the tests are failing because this'll no longer work with Svelte 1/2 — I think we can fix that by putting

const { compile, preprocess } = require('svelte/compiler');

after we've established major_version, and doing this:

const { compile, preprocess } = major_version >= 3
  ? require('svelte/compiler')
  : require('svelte');

@malkomalko malkomalko changed the title Get svelte-loader working with v3 alpha [WIP] Get svelte-loader working with v3 alpha Dec 30, 2018
@malkomalko
Copy link
Contributor Author

Cool, I'll fix the tests after coffee.

@malkomalko
Copy link
Contributor Author

This seems to be fine. I installed this with npm i svelte-loader@malkomalko/svelte-loader#svelte-v3 in my sapper project and things seem to be working. Feel free to give that a try and merge at your leisure.

@malkomalko malkomalko changed the title [WIP] Get svelte-loader working with v3 alpha Get svelte-loader working with v3 alpha Dec 30, 2018
@Rich-Harris Rich-Harris merged commit 88e00c1 into sveltejs:master Dec 30, 2018
@Rich-Harris
Copy link
Member

thanks! released 2.12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants