ruby-rdf / json-ld

Ruby JSON-LD reader/writer for RDF.rb
The Unlicense
232 stars 27 forks source link

Provide README examples for using a custom remote document loader #17

Closed dazza-codes closed 9 years ago

dazza-codes commented 9 years ago

There are currently no examples on how to set a persistent option on the jsonld API to use a custom document loader. The goal is to cache specific jsonld context documents using a custom document loader. (I'm running into pesky intermittent problems using rack-cache with rest-client and actually rack-cache is overkill for the purpose of only caching a few jsonld context docs.)

I'm looking for an example similar to this python code from @azaroth42 at https://github.com/azaroth42/anno_context_switcher/blob/master/context_switcher.py#L6-L25.