-
-
Notifications
You must be signed in to change notification settings - Fork 23
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
asset.package
is deprecated - fix
#9
Conversation
The getPackage() function is an asynchronous function and so you will need to use async/await to handle the function call. Calling it directly doesn't give the package.json file content. Error in console: Please use |
0345320
to
484ad91
Compare
@apvarun Thank you for checking it and informing me about my stupid mistake. :-) Could you review again? I've pushed another change - now I'm just resolving promise ( |
Changes look good regarding resolving the promise. But since"bundler.mainAsset.package.pkgfile" is still supported, the warning is still present. I guess the parcel version >= 1.9 should be resolved first before other cases. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changing the order of evaluation, version 1.9 and above to be evaluated first before older versions.
Well, TIL that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perfect!
Hello @Tolgor! Thank you for you comment. Could you provide some example to replicate this error? On my side everything is working as mentioned above. |
os: Windows 10 My local fixes Fix on getPackage() Promise await
Fix on destination resolution (was broken on Windows)
|
@apvarun please check and merge if it is ok. :-)
// edit: will fix #5