Open feklee opened 9 years ago
Looking at your ptp component, you need to fix the main
reference in your bower.json
file (https://github.com/feklee/ptp.js/blob/master/bower.json#L8). It should be pointing to a file (or multiple), not a directory. So that could be causing some of your problems.
Try changing it to this:
"main": "scripts/ptp.js"
Pointing "main"
to "scripts/ptp.js"
causes the issue that relative paths are not found. Pointing it to a directory is the only workaround that I found.
I installed my own package ptp.js. From
bower.json
:From
Gruntfile.js
:Resulting
config.js
:Now, to load
ptp.js
, the app's main module has:ptp.js
loads fine, but not any modules that it depends on. To fix this, I modifyconfig.js
to match what @jrburke does in his template for a simple one-page app:Then to load the module, I use:
Now, the dependencies load. The trick is to set the path to the directory containing the main module of the package to be loaded. If loaded as
ptp/ptp
, then relative paths work fine, otherwise not.I think there is design issue that needs to be discussed, or there is something that I don't understand.
What do you think?