GithubHelp home page GithubHelp logo

laura-guillory / shacl-form-example Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 4.0 83 KB

A minimal example for using the shacl-form package

License: GNU General Public License v3.0

Python 50.67% CSS 0.56% HTML 48.77%

shacl-form-example's Introduction

shacl-form-example

This application is a minimal demonstration of how to use the shacl-form package. It reads the SHACL Shape stored in shape.ttl and uses shacl-form to generate the files necessary to serve a form that facilitates the input of RDF data.

shape.ttl contains an example SHACL Shape. You can edit this to see how shacl-form reacts to different SHACL Shapes.

License

This work is licensed using the GPL v3 license. See LICENSE for the deed.

Contacts

Laura Guillory
Lead Developer
Informatics Software Engineer at CSIRO Land & Water
[email protected]

Nicholas Car
Product Owner
Senior Experimental Scientist
CSIRO Land & Water
[email protected]

How to use

  • Run app.py
  • Navigate to http://localhost:5000/
  • Click 'Generate Form'. The application will read shape.ttl and generate all the files necessary to serve the form
  • Fill out the form and submit
  • The results will be stored in result.ttl

shacl-form generates two files:

  • view/templates/form_contents.html is a Jinja2 template which extends form.html. You will want to edit form.html to control where your form appears on your site.
  • map.ttl is a Turtle RDF file which is used to convert information submitted to the form back into RDF.

These two files are a pair and can't be interchanged with files generated for another shape. They will only need to be generated once, but if you want to change the form, you can delete them to generate new ones.

shacl-form-example's People

Contributors

laura-guillory avatar nicholascar avatar

Stargazers

 avatar

Watchers

 avatar

shacl-form-example's Issues

Docker image

Is there docker image available for this application?

Bug with webforms.js

Hello,

I wanted to toy a little with this example . For that I found a problem on the load of the form, where input fields were either disabled or hidden. Looking at the problem in detail I found a 403 error in accesing webforms.js on rawgit. It happens that since 2019 rawgit is not available anymore. So I fix this issue by adding it to my app js folder and it works!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.