shekhargulati / 52-technologies-in-2016

Let's learn a new technology every week. A new technology blog every Sunday in 2016.
https://shekhargulati.com/
MIT License
7.21k stars 597 forks source link

Week 25: Trello Clone with Angular Dragulla #31

Open shekhargulati opened 8 years ago

shekhargulati commented 8 years ago

Please provide your feedback by posting a comment against this issue.

chainkite commented 8 years ago

When I follow your tutorial to step 4. I got this:

$ gulp serve
[11:49:29] Using gulp file /.../trello/gulpfile.js
[11:49:29] Starting 'scripts'...
[11:49:30]
/.../trello/src/app/index.module.js
  1:2  error  Parsing error: Illegal import declaration

✖ 1 problem (1 error, 0 warnings)

[11:49:30] all files 13.52 kB
[11:49:30] Finished 'scripts' after 645 ms
[11:49:30] Starting 'inject'...
[11:49:30] [AngularFilesort] Error in plugin 'gulp-angular-filesort'
Message:
    Error in parsing: "index.module.js", Line 1: Unexpected reserved word
shekhargulati commented 8 years ago

@chainkite as per the error message index.module.js has illegal import statement. Can you share content of index.module.js file?

chainkite commented 8 years ago
import { config } from './index.config';
import { runBlock } from './index.run';
import { MainController } from './main/main.controller';
import { WebDevTecService } from '../app/components/webDevTec/webDevTec.service';

angular.module('trello', ['ngAnimate', 'ngCookies', 'ngTouch', 'ngSanitize', 'ngMessages', 'ngAria', 'toastr', angularDragula(angular)])
  .config(config)
  .run(runBlock)
  .service('webDevTec', WebDevTecService)
  .controller('MainController', MainController)

Same from the tutorial. It seems dont know what is import. I am not quite familiar with javascript.

shekhargulati commented 8 years ago

@chainkite I think it is because you didn't selected ES6 (Babel formerly 6to5), ECMAScript 6 compiled with Babel which requires no runtime. as answer to Which JS preprocessor do you want? question. This question is asked when you run yo gulp-angular command as shown in the image. I missed this in the tutorial. screen shot 2016-06-27 at 12 02 20 pm

chainkite commented 8 years ago

I see, thanks a lot. BTW, this step is missing in the tutorial.

Is it possible to make the change of .yo-rc.json effective instead of regenerate the project?

natchiketa commented 8 years ago

@shekhargulati I am absolutely in love with the way you've set up this repo as a blog. The more I look at how it all works—Issues used as threads for a post, the repo home showing all the posts, subdirectories with the README as the post, plus containing any relevant source.

You could even have someone do a "guest post" submitted as a PR :)

Before I run off and gush about this, I'm curious—did you pick this up somewhere or are you just a freakin' genius?

shekhargulati commented 8 years ago

@natchiketa thanks for your comment. I am just a normal guy. In 2013, I wrote 30 technologies in 30 days https://blog.openshift.com/learning-30-technologies-in-30-days-a-developer-challenge/. From then I am thinking to do something like that again. There were couple of lessons I learnt after that series:

  1. I wanted it to write it as an open source project so people can contribute. Also, license should be liberal so that people can use it.
  2. I wanted to spend more time on one technology rather than just a single day.

So, finally in December last year I came up with this idea to spend my full year learning, building, and writing about different technologies. And as they say,

Rome was not built in a day

So, it's been now 6 months so a lot of effort and weekends have gone into all this :)

Thanks a lot for your comment. Loved it. Also, I am open to PR if you would like to contribute a post :)