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

docs: add examples of per-version validation #543

Merged
merged 1 commit into from
Dec 8, 2020

Conversation

Mearman
Copy link
Contributor

@Mearman Mearman commented Dec 7, 2020

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

Copy link
Member

@ctavan ctavan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess runmd stumbles when you put both imports into one line? Because we actually just hack our way around ESM

Copy link
Contributor Author

@Mearman Mearman Dec 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hahah yeah it wasn't happy about it at all.
Want me to submit it as an issue over on runmd?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

Copy link
Member

@broofa broofa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

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