https://github.com/donejs/donejs-bootstrap
A DoneJS generator for adding a Bootstrap UI with optional auth
https://github.com/donejs/donejs-bootstrap
Last synced: 9 months ago
JSON representation
A DoneJS generator for adding a Bootstrap UI with optional auth
- Host: GitHub
- URL: https://github.com/donejs/donejs-bootstrap
- Owner: donejs
- License: mit
- Created: 2017-06-26T21:57:52.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2019-06-20T16:54:56.000Z (almost 7 years ago)
- Last Synced: 2024-12-31T22:28:54.267Z (over 1 year ago)
- Language: JavaScript
- Size: 91.8 KB
- Stars: 0
- Watchers: 5
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: readme.md
- License: license.md
Awesome Lists containing this project
README
# donejs-feathers - Full-stack realtime
[](https://travis-ci.org/feathersjs/donejs-feathers)
[](http://badge.fury.io/js/donejs-feathers)

A generator to quickly add FeathersJS to your DoneJS project.
## Using the generator
To add this generator to your DoneJS application run
```
donejs add feathers
```
DoneJS and FeathersJS make for a killer full-stack solution for creating apps. This generator creates all of the model files and utilities needed to get both working together quickly. The current `2.x` version only sets up the model layer of the app. UI generation will move to separate generators sometime in the future.
**This generator could potentially overwrite files in an existing application. It is meant to be used immediately after generating a new DoneJS application.**
Here's a summary of the files that will be added or modified in a DoneJS project. To understand more about how these modules work together, check out the [`can-connect-feathers` documentation](https://canjs.com/doc/can-connect-feathers.html).
- `app.js` - a `session` property is added to the `AppViewModel` that reads from the `Session` model's `current` property.
- `models/algebra.js` - contains algebra for `can-connect` that enables support for the Feathers query syntax.
- `models/behaviors.js` - contains the minimum `can-connect` behaviors that are needed to work with Feathers and realtime data. The Feathers behaviors are added in the individual Model files, like `user.js` and `session.js`.
- `models/feathers-client.js` - sets up the Feathers client with Socket.io and points it to the location of the Feathers server. It also configures all of the npm-installed Feathers plugins.
- `models/fixtures.js` - includes mocks that simulate auth if you don't have a Feathers server running.
- `models/session.js` - handles authentication. It connects the `Session` model to the `can-connect-feathers/session/` behavior. It also automatically populates the `user` data using the `User` model.
- `models/user.js` a basic User model. It uses the `can-connect-feathers/service/` behavior to connect to the Feathers server. The default user endpoint is `/users`, but can be modified here.
The following packages will be added to your project from npm:
- `can-connect-feathers`
- `feathers`
- `feathers-hooks`
- `feathers-socketio`
- `feathers-authentication-client`
- `steal-socket.io`
- `socket.io-client`
## Developing
To make changes to this generator clone the repository and install the dependencies
```
git clone git@github.com:feathersjs/donejs-feathers.git
cd donejs-feathers
npm install
```
Then you can run the tests with
```
npm test
```