Repository navigation
Collections
A shared data storage that components can use. Example: A component that creates and stores form data, can store it in the collections so another component can see or use the same data. It'll save it, and persist between app loads.
var collections = document.querySelector("ceci-collections");
collections is a thing you can call collections related functions from. You can access this and use it from inside your component.
collections.addSchema(name)
collections.removeSchema(schemaid)
collections.getSchema(schemaid)
collections.getSchemas()
collections.getField(schemaid, fieldid)
collections.getFields(schemaid)
Listen for changes in schema or data. You can add events using collections.addEventListener(event, function() {})
schemachange
var schema = collection.getSchemas()[0];
schema is a thing you can call schema related functions from. You can access this and use it from inside your component.
schema.addField(name)
schema.removeField(fieldid)
schema.getField(fieldid)
schema.getFields()
schema.name
schema.addItem(item)
schema.removeItem(index)
schema.updateItem(index, item)
schema.saveData()
Listen for changes in schema or data. You can add events using schema.addEventListener(event, function() {})
itemchange
fieldchange
propertychange
var field = schema.getFields()[0];
field is a thing you can call field related functions from. You can access this and use it from inside your component.
field.kind
field.name
field.getSchemaId()
propertychange