-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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
[1.3 beta] issue on global space inside local package. #5819
Comments
I ran your app on Meteor 1.3-modules-beta.0 and saw the following error in the console:
Then I ran it with Meteor 1.2.1 and got the same error. Are you sure this repro demonstrates the problem you are hitting? |
You are right @avital. This repo not fail! .. Sorry for that. |
@stubailo told me that he also hit something similar. Maybe he'll find a repro as well. But let's keep looking, if this is a real problem. |
Fixed in 1.3b1: #5788 (comment) |
@benjamn, still have problems with globals on Beta1. This time with ...
You can reproduce it creating a |
I create a package package.js
global.js
and this solve: But now I have a new one:
|
Prior to this change, linker’s package global variable scanning mechanism was broken. All package global variables were exposed as full global variables. This was due to calling `escope`’s `analyzeScope` function with `{sourceType: "modules"}`. While at it, fixed incorrect code that exposes `process` on the client. The previous code seemed to work to work because we were exposing all package globals as real globals. Should fix #5870 and #5819
I update a project from 1.2.1 to 1.3 beta0 and my local packages, more of then npm wrappers around jQuery plugins, can´t found jQuery or '$' global.
I create a minimal repo with a jQuery plugin on a local package for reproduction.
This example work fine on 1.2.1 even without add 'jquery' inside package. But is not the case with 1.3.
My impression it is a problem between global Meteor scope and IIFE that not find jQuery on
window
global object. Maybe when IIFE is called Meteor environment is not yet set??This a test repo: https://github.com/bySabi/bug-on-1.3-beta0-with-jqueryplugin-package
The text was updated successfully, but these errors were encountered: