Commit f925c2f3 authored by Tobias Steiner's avatar Tobias Steiner
Browse files

Update example and readme

parent 68256ac2
# Geolinker widget
# Histhub widget
The histhub widget can display sameas resources from histhub linking services. You can integrate it into your site and display links to other providers. __The widget and the apis are in beta status. They may change in the future.__
## Webcomponent
The widget itself is a [webc omponent]( It integrates smoothly into an existing website. You just need to add some markup and load a javascript file.
## Integration
Just have a look at the examp,e folder. There you can find a set of working examples.
<!-- load the script in your header -->
<script src="../src/histhub-widget.js"></script>
<!-- add the component wehre you like to display the links -->
<histhub-widget endpoint="ENDPOINT" resolver="RESOLVER" location="URL TO LOOK FOR"></histhub-widget>
## API
### Endpoint
The endpoint defines the restapi, where the widget makes the call to get the links. Currently we provide three endpoints for different resource types.
* Tagcloud
* Geolinker
* Geolinker
* Orgalinker
Choose one of the endpoint to get links for your resource
### Resolver
The endpoint uses different technologies to generate the links. Those technologies calls resolver. You need to define a resolver to get the links for your preferences.
__Tagcloud and Orgalinker__
For those two services we provide the `resolvermanual` . The links provided by this resolver are done by humans. See examle 1 and example 2
The geolinker provides for the `sameas` endpoint the `resolverneo4j` resolver. The links provided by this resolver are done semiautomatical. See example 3
For the `similarto` endpoint the geolinker provides a `elasticsearchresolver`. The data are guessed based on a matching algorithm. See example 4
### Location
The location is an optional parameter. By default the widget uses the current window.location.href to make the request. You can specify the url to look for over the url parameter
......@@ -23,7 +23,10 @@
<h3 slot="title">Example 2: Links from orgalinker dodis: Lombard, Odier & Cie</h3>
<histhub-widget endpoint="//" resolver="resolverneo4j" location="">
<h3 slot="title">Example 3: Links from geolinker dodis: Diedenhofen</h3>
<h3 slot="title">Example 3: Links (sameas) from geolinker dodis: Diedenhofen</h3>
<histhub-widget endpoint="//" resolver="resolverelasticsearch" location="">
<h3 slot="title">Example 4: Links (similarto) from geolinker dodis: Diedenhofen</h3>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment