docs: add examples of per-version validation#543
Merged
ctavan merged 1 commit intouuidjs:masterfrom Dec 8, 2020
Merged
Conversation
ctavan
approved these changes
Dec 7, 2020
Member
ctavan
left a comment
There was a problem hiding this comment.
Apart from putting both imports into one statement (which is probably currently not supported by runmd) I really like this! Thank you 🙇♂️
|
|
||
| ```javascript | ||
| import { version as uuidVersion } from 'uuid'; | ||
| import { validate as uuidValidate } from 'uuid'; |
Member
There was a problem hiding this comment.
I guess runmd stumbles when you put both imports into one line? Because we actually just hack our way around ESM…
Contributor
Author
There was a problem hiding this comment.
Hahah yeah it wasn't happy about it at all.
Want me to submit it as an issue over on runmd?
Member
There was a problem hiding this comment.
Want me to submit it as an issue over on runmd?
Yes, please. I'm aware of the issue but need to revisit it to see if there's a better solution than the one ctavan and I hacked in a while ago.
This was referenced Mar 12, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Created in lieu of specific per-version validation methods as seen in #542
Might be something stupid I'm doing but for some reason, having the two aliased imports caused
SyntaxError: Cannot use import statement outside a module