Skip to content

Lab 11-12 Kaylyn#13

Open
kaylynyuh wants to merge 18 commits intocodefellows-seattle-javascript-401d10:masterfrom
kaylynyuh:master
Open

Lab 11-12 Kaylyn#13
kaylynyuh wants to merge 18 commits intocodefellows-seattle-javascript-401d10:masterfrom
kaylynyuh:master

Conversation

@kaylynyuh
Copy link
Copy Markdown

Still have work to do, had to start from scratch. Good times.

Raziyehbazargan pushed a commit to Raziyehbazargan/lab-11-12-express-api that referenced this pull request Sep 27, 2016
@kaylynyuh kaylynyuh changed the title Lab 11 Kaylyn Lab 11-12 Kaylyn Sep 28, 2016
Comment thread lab-kaylyn/README.md
@@ -0,0 +1,35 @@
## About The Program:
Copy link
Copy Markdown

@bnates bnates Sep 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh great README!

Comment thread lab-kaylyn/gulpfile.js
gulp.watch(['./*.js','**/*.js','./lib/*.js'],['eslint','test']);
});

gulp.task('default',['watch']);
Copy link
Copy Markdown

@bnates bnates Sep 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh gulpfile looks good - try adding new tasks if you find that you need them!

err = createError(500, err.message);
res.status(err.status).send(err.name);
next();
};
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh error middleware looks good

Comment thread lab-kaylyn/lib/storage.js

const Promise = require('bluebird');
const createError = require('http-errors');
const del = require('del');
Copy link
Copy Markdown

@bnates bnates Sep 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh nice job researching and using the del module!

this.projects = projects;
this.work = work;
debug('about', this.about);
debug('projects', this.projects);
Copy link
Copy Markdown

@bnates bnates Sep 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh great Portfolio constructor, inclusion of debug statements, and error handling for your about, projects, and work properties

.catch(err => next(err));
});

//now using params
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh great!

.catch(next);
});

module.exports = portfolioRouter;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh get, post, put, and delete methods look great - excellent use of middleware for parsing json on your put route

Comment thread lab-kaylyn/server.js
const PORT = process.env.PORT || 3000;
const app = express();

app.use(morgan('dev'));
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh maybe cluster the app.use() statements together?

Comment thread lab-kaylyn/server.js

app.listen(PORT, function(){
debug(`server up ${PORT}`);
});
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh server file looks good

});
});
});
});
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kaylynyuh LOTS of tests! AWESOME! No nitpicks here, keep focusing on the TDD side of things and learning to write tests will get easier and not as much of a headache

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants