Skip to content
This repository was archived by the owner on Aug 4, 2021. It is now read-only.

Create an error with a code frame when parsing fails#288

Merged
lukastaegert merged 1 commit intorollup:masterfrom
unstubbable:error-code-frame
Mar 5, 2018
Merged

Create an error with a code frame when parsing fails#288
lukastaegert merged 1 commit intorollup:masterfrom
unstubbable:error-code-frame

Conversation

@unstubbable
Copy link
Contributor

By calling this.error in transform instead of throwing the error directly (in tryParse) rollup will augment the error and add a code frame based on the given location before throwing it.

By calling `this.error` in `transform` instead of throwing the error
directly (in `tryParse`) rollup will augment the error and add a code
frame based on the given location before throwing it.
Copy link
Member

@lukastaegert lukastaegert left a comment

Choose a reason for hiding this comment

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

I like it, thanks!

@lukastaegert lukastaegert added this to the 8.4.0 milestone Mar 5, 2018
@lukastaegert lukastaegert merged commit 9674a6c into rollup:master Mar 5, 2018
@unstubbable unstubbable deleted the error-code-frame branch March 5, 2018 08:23
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants