You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What would be the best way to integrate YASGUI with a graph database that works locally? That is, to respond to SPARQL queries from within JavaScript without sending an HTTP request? Oxigraph is an example of a graph database and SPARQL query engine that can be included in the browser via WebAssembly.
One way to accomplish this currently is to listen to the query event from yasqe, rebuild the query from the request data, and abort the default HTTP request. But this seems like something that could break in the future. For example, if fetch were used as the HTTP request library (#150). (Cancelling fetch requests is a bit more involved than calling .abort()).
The text was updated successfully, but these errors were encountered:
We noticed as well that yasqe's interface suited for local graph instances. One way to do it would be to override yasqe.query with something like
constyasqe=newYasqe(...)yasqe.query=(yasqeInstance)=>{constqueryString=yasqeInstance.getValue()...// When using YasguiyasqeInstance.emit("queryResponse",jsonResponse);// When using Yasryasr.setResults(jsonResults)}
What would be the best way to integrate YASGUI with a graph database that works locally? That is, to respond to SPARQL queries from within JavaScript without sending an HTTP request? Oxigraph is an example of a graph database and SPARQL query engine that can be included in the browser via WebAssembly.
One way to accomplish this currently is to listen to the
query
event fromyasqe
, rebuild the query from the request data, and abort the default HTTP request. But this seems like something that could break in the future. For example, iffetch
were used as the HTTP request library (#150). (Cancellingfetch
requests is a bit more involved than calling.abort()
).The text was updated successfully, but these errors were encountered: