1.1.14 • Published 10 months ago
@gradii/fedaco v1.1.14
Fedaco Orm
can visit document via site
How To Use It
- setup a connection
const db = new DatabaseConfig(); db.addConnection({ 'driver' : 'sqlite', 'database': ':memory:' }); db.bootFedaco(); db.setAsGlobal();
define a model
@Table({ tableName: 'user' }) class User extends Model { @PrimaryColumn id; @Column() email; @Column() name; @Column() age; @CreatedAtColumn() created_at; @UpdateAtColumn() updated_at; }
fetch data
const list = await User.createQuery().get();
Create Table
create a user table.
const schemaBuilder = schema(connectionName);
await schemaBuilder().create('users', table => {
table.increments('id');
table.string('email').withUnique();
table.string('name');
table.string('age');
});
Features
- wrapped driver. unify all driver query api
- compile query builder to sql
- decorate to define model
- soft delete
- use relationship to link model
- relation can set dynamic constrain
- sqlite and mysql support
1.1.14
10 months ago
1.1.13
10 months ago
1.1.1
1 year ago
1.1.0
1 year ago
1.0.0
1 year ago
1.1.9
1 year ago
1.1.8
1 year ago
1.1.7
1 year ago
1.1.6
1 year ago
1.1.5
1 year ago
1.1.4
1 year ago
1.1.3
1 year ago
1.1.2
1 year ago
1.1.12
11 months ago
1.1.11
12 months ago
1.1.10
12 months ago
0.0.17
1 year ago
0.0.15
2 years ago
0.0.16
2 years ago
0.0.14-beta.0
2 years ago
0.0.14-beta.1
2 years ago
0.0.13
2 years ago
0.0.14
2 years ago
0.0.12
3 years ago
0.0.11
3 years ago
0.0.10
3 years ago
0.0.9
3 years ago
0.0.8
3 years ago
0.0.5
3 years ago
0.0.7
3 years ago
0.0.6
3 years ago
0.0.3
4 years ago
0.0.4
4 years ago
0.0.2
4 years ago
0.0.1
4 years ago
0.0.1-beta.6
4 years ago