diff --git a/CHANGELOG.md b/CHANGELOG.md index 802f4ce..5cdaafb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -# @kopflos/core +# @kopflos-cms/core ## 0.1.0 diff --git a/README.md b/README.md index c254f05..90f4dae 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# @kopflos/core +# @kopflos-cms/core [Hydra](http://www.hydra-cg.com/spec/latest/core/) is a machine readable description for APIs. Kopflos extends the API description with links to the actual code, which provides the API. @@ -8,7 +8,7 @@ Kopflos will use such an API description to create an express middleware which p ### Application -`@kopflos/core` uses an object that implements the [RDF/JS Store interface](http://rdf.js.org/stream-spec/#store-interface) to read resources and find types of resources to identify matching operations. +`@kopflos-cms/core` uses an object that implements the [RDF/JS Store interface](http://rdf.js.org/stream-spec/#store-interface) to read resources and find types of resources to identify matching operations. The resource is read using the IRI as named graph filter. Here an example for a store on the local file system using `rdf-store-fs`: @@ -43,7 +43,7 @@ app.listen(9000) ### Operation The operations must implement a [Express routing handler](http://expressjs.com/en/starter/basic-routing.html) interface (`(req, res, next) => {}`). -@kopflos/core adds the [@rdfjs/express-handler](https://github.com/rdfjs-base/express-handler) to handle incoming and outgoing RDF data. +@kopflos-cms/core adds the [@rdfjs/express-handler](https://github.com/rdfjs-base/express-handler) to handle incoming and outgoing RDF data. For `GET` requests with a matching IRI Template, the `.dataset()` and `.quadStream()` as defined by `express-handler` are also available to read the given variables. Additionally there is a `hydra` property assigned to `req` that contains more data about the request: diff --git a/package-lock.json b/package-lock.json index 3cd823d..0c850e8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,11 +1,11 @@ { - "name": "@kopflos/core", + "name": "@kopflos-cms/core", "version": "0.1.0", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "@kopflos/core", + "name": "@kopflos-cms/core", "version": "0.1.0", "license": "MIT", "dependencies": { diff --git a/package.json b/package.json index 44de9f4..a54c923 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "@kopflos/core", + "name": "@kopflos-cms/core", "description": "Hydra middleware for web APIs", "version": "0.1.0", "main": "index.js", diff --git a/test/middleware.test.js b/test/middleware.test.js index 2ef34a0..a88b9eb 100644 --- a/test/middleware.test.js +++ b/test/middleware.test.js @@ -12,7 +12,7 @@ import hydraBox from '../middleware.js' const example = RDF.namespace('http://example.org/') -describe('@kopflos/core', () => { +describe('@kopflos-cms/core', () => { let api beforeEach(() => {