Closed stefannegele closed 8 years ago
I think test
folder ignore in .npmignore
file or add files field in moment-precise-range/package.json
{
"name": "moment-precise-range-plugin",
"version": "1.1.1",
"description": "This is a plugin for the moment.js JavaScript library, to display date/time ranges precisely, in a human-readable format.",
"files": [
"*.md",
"moment-precise-range.js"
],
"main": "moment-precise-range.js",
"directories": {
"test": "test"
},
"scripts": {
"test": "cd test && node node-tests.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/codebox/moment-precise-range.git"
},
"tonicExampleFilename" : "example/example.js",
"author": "Rob Dawson <rob@codebox.org.uk> (http://codebox.org.uk)",
"license": "MIT",
"bugs": {
"url": "https://github.com/codebox/moment-precise-range/issues"
},
"homepage": "https://github.com/codebox/moment-precise-range#readme"
}
@LasTanzen does the fix proposed by @jeongsd fix your issue? If so I will merge it in
@codebox Yep, seems to work!
Thanks a lot!
Hi there! Doest'n suit for me, problem still remains. Also with webpack. I'm using moment-precise-range-plugin@1.2.0 on npm v3.8.3 and node v5.10.1
.../private_site/static_member/frontendsource/node_modules/webpack-core/lib/NormalModuleMixin.js:163
if(isError) throw e;
^
Error: ./~/moment-precise-range-plugin/test/node-tests.js
Module not found: Error: Cannot resolve module 'jasmine' in .../private_site/static_member/frontendsource/node_modules/moment-precise-range-plugin/test
resolve module jasmine in .../private_site/static_member/frontendsource/node_modules/moment-precise-range-plugin/test
looking for modules in .../private_site/static_member/frontendsource/node_modules
.../private_site/static_member/frontendsource/node_modules/jasmine doesn't exist (module as directory)
resolve 'file' jasmine in .../private_site/static_member/frontendsource/node_modules
resolve file
.../private_site/static_member/frontendsource/node_modules/jasmine doesn't exist
.../private_site/static_member/frontendsource/node_modules/jasmine.js doesn't exist
.../private_site/static_member/frontendsource/node_modules/jasmine.rt doesn't exist
[.../private_site/static_member/frontendsource/node_modules/jasmine]
[.../private_site/static_member/frontendsource/node_modules/jasmine]
[.../private_site/static_member/frontendsource/node_modules/jasmine.js]
[.../private_site/static_member/frontendsource/node_modules/jasmine.rt]
@ ./~/moment-precise-range-plugin/test/node-tests.js 1:14-32
Issue is still there in the published npm package, please bump the version there.
I am running to this problem with npm and webpack. Seems like npm still gives the old version of the package.json.
Yep, I get this issue here too!
Yes. I'm still get this problem. Any way to solve it?
We're still using it as "moment-precise-range-plugin": "github:codebox/moment-precise-range"
in dependencies.
@codebox If you're still around please consider fixing your npm package
@darkalor @xeii @brunowego @dracudakid I have incremented the package version on npm, please let me know if that fixes things for you
First, thanks for this. It´s really helpful!
I came across some weird dependecy-errors from jasmine (don´t know if related), since i installed (npm) and required your plugin, and then building with webpack. However, the build itself seems to work. I temporary uninstalled jasmine to prevent unrelated errors and here is what webpack tells me know after building:
I´m kind of confused since this is not happening with any other module. I don´t even find the place where 'node-tests-js' is loaded. Funny thing: If i delete the folder test in the modules folder, there´s no error occuring anymore.
It seems it has something to do with your test code or some missing dependencies. Tell me, if i can help you bugfixing.
Or is it my shitty webpack configuration?
Thanks and regards, Stefan