Comments (3)
I have created a small application that demonstrates the problem. You can see double loading in "Net" tab in Firebug or in console in Firebug/Chrome. The application can be downloaded using the following URL:
http://www.mediafire.com/file/mth9d9owmb32d35/curl-js-file-double-loading-bug.zip
from curl.
Thanks for discovering this, gamtiq!
The solution for this is to add the normalize() method to the js! plugin.
This method allows the js! plugin to determine the uniqueness of a
resource id.
Do you need a work-around for now or can you continue to work for a few
days without this fixed?
Regards,
-- John
On Mon, Nov 7, 2011 at 3:06 AM, gamtiq <
[email protected]>wrote:
Hello,
First of all I would like to thank you for the great loader. It is very
useful.
I found a bug in curl.js that leads to problems when a JS file is used as
a dependency with and without !order option. Namely, if one module depends
on "someFile.js" and another module depends on "someFile.js!order", then
this situation causes double loading of "someFile.js". As a result some
strange and difficult to find bugs can occur in an application. The problem
has its roots in the following part of fetchDep function (lines 541 and
542 in curl.js):name = prefix + '!' + resName; normalizedDef = cache[name];
As you can see there is no test for options in "resName".
Best regards.
Reply to this email directly or view it on GitHub:
https://github.com/unscriptable/curl/issues/30
from curl.
No, I don’t need immediate fix for this issue because I have already found and implemented a work-around in my application.
from curl.
Related Issues (20)
- curl-css shouldn't wait for readystate == 'complete' HOT 7
- What if the module is a function? HOT 1
- Similar functionality of curl with require.js map config? HOT 1
- Using domReady! as a dependency argument causes an error HOT 4
- dealing with the window object HOT 7
- Unhandled error is eaten by curl when bootstrap code has a json plugin dependency HOT 5
- For anyone facing the error : Multiple anonymous defines encountered HOT 1
- Multiple bundles HOT 17
- Remove old IE event listeners in domReady HOT 1
- License for curl HOT 4
- "undefined" from import when define function throws an exception HOT 8
- Modules "undefined" when error occurs HOT 1
- "new Promise()" syntax non-standard? HOT 1
- Promise.then doesn't wait HOT 5
- Add build with js plugin
- multiple anonymous defines HOT 2
- How to help curl guess the right plugin? (e.g. json! for *.json) HOT 8
- Feature Request: Add syntax to bypass plugins
- cjsm11 loader hides a TypeError and falsely reports success
- 学习 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from curl.