Skip to content
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

fix: add check for template store to conditional #1829

Merged
merged 4 commits into from
Oct 30, 2018

Conversation

tivac
Copy link
Contributor

@tivac tivac commented Oct 30, 2018

Fixes #1828

This adds to the check introduced in #1811 so that it also handles components that set their own store via a function. Previously the check only looked for a passed-in store from options.

Svelte tests have traditionally been very cranky on my machine, presumably due to being on Windows, but I'm working to try and update some tests and add at least one test to check this functionality.

@Conduitry
Copy link
Member

I think I'd prefer putting the && !templateProperties.store check in the compiler code that decides whether to output this bit of code, rather than in the client code.

@tivac
Copy link
Contributor Author

tivac commented Oct 30, 2018

@Conduitry Fair, updated with a test and logic moved into the compiler!

@Conduitry Conduitry merged commit cb4a46d into sveltejs:master Oct 30, 2018
@tivac tivac deleted the issue-1828 branch October 30, 2018 17:33
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