[Cubicweb] Single Page Application/REST

Nicolas Chauvat nicolas.chauvat at logilab.fr
Fri Apr 24 13:06:55 CEST 2020


Hi Gary,

On Thu, Apr 23, 2020 at 07:25:30PM -0400, Gary Albelli wrote:

> Is it possible to use a framework like Vue.js to develop a Single Page Application with CubicWeb?
> As a follow on question, is there an ability to generate restful services from the model? 

Yes.

Define your data model and initialize your application.

Use https://www.cubicweb.org/project/cubicweb-rqlcontroller to provide
a query API on the route /rqlio (similar to providing a /__graphql
entry point).

On the client side, use https://www.npmjs.com/package/@logilab/cwclientlibjs

Then, use Vue, or React, or plain js/ts if that's how you do it.

You may want to look at
https://www.npmjs.com/package/@logilab/cwelements as an exemple of
building react components that display the data held in a CubicWeb
application queried via /rqlio.

-- 
Nicolas Chauvat

logilab.fr - services en informatique scientifique et gestion de connaissances  



More information about the Cubicweb mailing list