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: declare variables which should not be managed by inline-snapshot #569

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

15r10nk
Copy link

@15r10nk 15r10nk commented Nov 4, 2024

things which can be changed with the next inline-snapshot version to make clear who is responsible for the source code (inline-snapshot or the developer).

@alexmojaki
Copy link
Contributor

I don't understand this. What's the difference between Is(foo) and foo when foo is a variable name?

@15r10nk
Copy link
Author

15r10nk commented Nov 4, 2024

@alexmojaki, you are fast 😄.

I published this to show what I'm currently working on 15r10nk/inline-snapshot#123.

This makes only sense if you know that Is(...) will be a part of the next inline-snapshot version which allows the developer to take back control and to change code inside snapshots.

This makes it explicit who controls the source code and inline-snapshot will no longer try to change you code back with "update".

The value inside Is(...) can also change if the snapshot is evaluated multiple times and allow some constructs which are not possible today.

@samuelcolvin
Copy link
Member

thanks, personally I think this looks good, but @alexmojaki and @Kludex mostly maintain this repo, so it's up to them.

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.

3 participants