mirror of
https://github.com/strapi/strapi.git
synced 2025-11-10 15:19:00 +00:00
32 lines
1.1 KiB
Markdown
32 lines
1.1 KiB
Markdown
|
|
# strapi-generate-model
|
||
|
|
|
||
|
|
[](https://www.npmjs.org/package/strapi-generate-model)
|
||
|
|
[](https://www.npmjs.org/package/strapi-generate-model)
|
||
|
|
[](https://david-dm.org/wistityhq/strapi-generate-model)
|
||
|
|
[](https://travis-ci.org/wistityhq/strapi-generate-model)
|
||
|
|
[](http://slack.strapi.io)
|
||
|
|
|
||
|
|
This Strapi generator contains the default files for a model.
|
||
|
|
|
||
|
|
This generator can be called with:
|
||
|
|
|
||
|
|
```bash
|
||
|
|
$ strapi generate:model modelName apiName
|
||
|
|
```
|
||
|
|
|
||
|
|
For example if you want to generate a `group` model for the `user` API:
|
||
|
|
|
||
|
|
```bash
|
||
|
|
$ strapi generate:model group user
|
||
|
|
```
|
||
|
|
|
||
|
|
## Resources
|
||
|
|
|
||
|
|
- [MIT License](LICENSE.md)
|
||
|
|
|
||
|
|
## Links
|
||
|
|
|
||
|
|
- [Strapi website](http://strapi.io/)
|
||
|
|
- [Strapi community on Slack](http://slack.strapi.io)
|
||
|
|
- [Strapi news on Twitter](https://twitter.com/strapijs)
|