-
Notifications
You must be signed in to change notification settings - Fork 0
Add a collection schema
You want to define how a collection of data is structured.
Add a JSON schema file to /app/schemas/models.
We use JSON schema both on the client and on the server to enforce data integrity, document intended structure, validate forms, and generate some interfaces. Though the file is located in /app, the server will also load the file and should use it whenever changes are made to a document. These are not hard and fast schemas, though, there is nothing preventing the server logic from making changes without checking the schema, or changing the schema in such a way that existing data becomes 'invalid'.
Make sure to read through the JSON Schema website for how schemas are structured, in particular the JSON Schema Validation Specification.
We us a schemas module to generate many of our schemas, rather than write them all from scratch.
CodeCombat | Home | Blog | Forum | Teachers | Legal | Contribute
- Home
- Archmage Home
- Artisan Home
- Adventurer Home
- Scribe Home
- Diplomat Home
- Ambassador Home
- Archmage General
- Mission statement
- Coco Models
- Coding Guidelines
- Cookbook
- File system
- JSON Schema
- Technical overview
- Testing
- Third party software and services
- Artisan General
- Building A Level
- Coding Guidelines for Artisans
- Editing Thang Components
- Important Artisan Concepts
- Keyboard Shortcuts
- Artisan How-To Index
- Adventurer General
- Scribe General
- Diplomat General
- i18n
- i18n Glossary nb
- i18n Glossary ru
- i18n Glossary es-419
- Ambassador General
- Dev Setup
- Dev Setup: Linux
- Dev Setup: Windows
- Dev Setup: Mac
- Dev Setup: Vagrant
- Dev Setup: Issues
- Game Engine
- Component
- Multiplayer
- Surface
- System
- Thang
- Thang Component System
- Tome
- World
- Artisan Tabs
- Components And Systems
- Scripts
- Settings
- Thangs
- Other
- Aether
- Client models
- Developer organization
- Educational Standards
- Events, subscriptions, shortcuts
- Chat Room
- Chat Room Rules
- Permissions
- Project Ideas List
- Treema
- Versioning
- Views