Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Matterwiki 0.3.0 #152

Draft
wants to merge 366 commits into
base: master
Choose a base branch
from
Draft

Matterwiki 0.3.0 #152

wants to merge 366 commits into from

Conversation

krishnagopinath
Copy link
Collaborator

nshntarora and others added 30 commits June 27, 2017 05:02
There's too much to describe here. I'll try my best to describe what's going on:

* Moves server stuff into src/server
* Makes migration and seed script stuff into a CLI task than mucking it up with code
* New directory structure for the server:

.
├── app.js
├── index.js
├── middleware
│   ├── bodyParser.js
│   ├── checkAuth.js
│   └── checkRole.js
├── models
│   ├── archive.js
│   ├── article.js
│   ├── topic.js
│   └── user.js
├── routes
│   ├── articles.js
│   ├── auth.js
│   ├── setup.js
│   └── topics.js
└── utils
    ├── WDSStarter.js
    ├── buildDbModel.js
    ├── config.js
    ├── constants.js
    └── db.js

* Each file in routes could be its own thing, cos each of those make their own sub-routers
* app.js handles app-specific stuff
* index.js handles bootstrapping the server, webpack-dev-server and config management
* Adds new way to handle config via a `config.env` file, which is used for DB and other credentials
* We support ONLY MySQL as of now, which means Bye bye SQLITE!

TODO:

* Add config.env to gitignore
* Finish up the Admin specific stuff
* Update README
* Comments in the code, among other things
* Some error handling for config.js
* src/server => src/api
* Adds ESLint, prettier and related plugins for improving code quality
* Sets up ESLint + prettier as a pre-commit hook
* Runs some prettier format tests

* Fix ESLint errors in the code
…jest 🎉

Most of the stuff that's been done is in testHelpers/ of the api. There is some config for running a minimal jest setup in the root, as jest.config.js.

Changelog:
* Add testing rig, write tests for auth middleware and topicRouter
* Add tests for userRouter
* Setup modelHolders that can be used to share common stuff like tokens
* Add tests for setupRouter
* Add tests for the authRouter
* Add tests for topicsRouter
* Add global setup and teardown fns inside the individual test suites (because of jestjs/jest#1852 (comment))
* Make randomly named DBs for every suite so tests can be run in parallel
The `commit-msg` hook is not entirely gone, its still usable via `npm run cm`
@alingse
Copy link

alingse commented Sep 8, 2021

good can we make a release ?

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.

None yet

3 participants