aurelia / validatejs

Enables expressive validation using decorators and/or a fluent API.
MIT License
22 stars 23 forks source link

instructions to build/run sample are incorrect #20

Closed mbroadst closed 8 years ago

mbroadst commented 8 years ago

The readme indicates you should simply need to cd sample && npm install && jspm install && gulp start, however there are no gulp tasks in that directory

plwalters commented 8 years ago

https://github.com/aurelia/validatejs/blob/master/build/tasks/watch.js#L15 <~~~ serves the sample app up - and gulp should find it properly. Just double-checked and it looked good for me so you would need to let me know what is not working and I can look at it.

mbroadst commented 8 years ago

@PWKad Two issues here:

mbroadst@retinoid:sample (master=)$ gulp watch
[09:33:34] Working directory changed to ~/Development/aurelia/validatejs
[09:33:35] Using gulpfile ~/Development/aurelia/validatejs/gulpfile.js
[09:33:35] Starting 'build'...
[09:33:35] Starting 'clean'...
[09:33:35] Finished 'clean' after 43 ms
[09:33:35] Starting 'build-es2015'...
[09:33:35] Starting 'build-commonjs'...
[09:33:35] Starting 'build-amd'...
[09:33:35] Starting 'build-system'...
[09:33:38] Finished 'build-amd' after 2.7 s
[09:33:38] Finished 'build-commonjs' after 2.7 s
[09:33:38] Finished 'build-es2015' after 2.71 s
[09:33:38] Finished 'build-system' after 2.7 s
[09:33:38] Finished 'build' after 2.76 s
[09:33:38] Starting 'serve'...
[BS] Access URLs:
 --------------------------------------
       Local: http://localhost:3001
    External: http://192.168.11.55:3001
 --------------------------------------
          UI: http://localhost:3002
 UI External: http://192.168.11.55:3002
 --------------------------------------
[BS] Serving files from: sample
[09:33:38] Finished 'serve' after 150 ms
[09:33:38] Starting 'watch'...
[09:33:38] Finished 'watch' after 128 ms

Which has then just built your sample app in amd/commonjs/requirejs/etc and not loading your app where you think you're loading it.

So I guess I just think the issue should be reopened because there is no current way to run this app. I think the sample folder needs (at very least) its own gulpfile and set of build tasks.

HTH

plwalters commented 8 years ago

https://github.com/aurelia/validatejs/commit/c77f3693587a607393e73a90f01f5c39f53084f6 <~~

I'll add a note to run build-sample as well, thanks for helping to point this out.

plwalters commented 8 years ago

There was a problem with JSPM trying to incorrectly load one of the package paths that only exists in this scenario, not in a real app, that was fixed in there as well.

plwalters commented 8 years ago

Alright readme updated with working instructions.

aivins commented 8 years ago

Not working for me on master as of 5 minutes ago:

git clone https://github.com/aurelia/validatejs.git
cd validatejs
npm install
cd sample
npm install
jspm install
gulp build-sample
gulp watch

Then http://localhost:3000/

Uncaught (in promise) Error: Error: XHR error (404 Not Found) loading http://localhost:3000/jspm_packages/npm/aurelia-validation@0.8.0.js
    Error loading http://localhost:3000/jspm_packages/npm/aurelia-validation@0.8.0.js as
"aurelia-validation" from http://localhost:3000/aurelia-validatejs/index.js