In npm you can express the basic informaion about a project and its dependencies in the following manner:
{
"name": "dahut",
"version": "1.42.17",
"dependencies": {
"cryptozoology": "^0.9.2",
"jsdom": "1.2.7 || >=1.2.9 <2.0.0",| language: node_js | |
| branches: | |
| only: | |
| - gh-pages | |
| env: | |
| global: | |
| - URL="http://w3c.github.io/manifest/ECHIDNA" | |
| - DECISION="https://lists.w3.org/Archives/Public/public-webapps/2014JulSep/0627.html" |
| function HSVtoRGB (hsv) { | |
| // this doesn't work for the values of 0 and 360 | |
| // here's the hacky fix | |
| var h = hsv[0]; | |
| if (h === 0) h = 1; | |
| if (h === 360) h = 359; | |
| // Rebase the h,s,v values | |
| h = h/360; | |
| var s = hsv[1]/100 | |
| , v = hsv[2]/100 |
| // a quick and dirty tool to know what is taking up space in a bundle | |
| // this should be made generic | |
| // USAGE: | |
| // - save it somewhere | |
| // - replace `entryFile` with the path to your entry point | |
| // - check that the browserify options make some sort of sense | |
| // - run it | |
| // The output will be a long list of dependencies. The first is the entry point, after that they're ordered | |
| // by size. Each lists its size and what includes it. You can use that to get a feel for what can be usefully | |
| // optimised out. |
In npm you can express the basic informaion about a project and its dependencies in the following manner:
{
"name": "dahut",
"version": "1.42.17",
"dependencies": {
"cryptozoology": "^0.9.2",
"jsdom": "1.2.7 || >=1.2.9 <2.0.0",| // from the brilliant mind of sb | |
| var _catch = Promise.prototype.catch; | |
| Promise.prototype.catch = function () { | |
| return _catch.call(this, function (err) { setTimeout(function () { throw(err); }, 0); }); | |
| } | |
| <!-- | |
| NOTES: | |
| - this does not include affiliation for people: that is a more complex situation (we might be happy with just the ORCID). | |
| - there is no specific subtyping information, I am unsure what to do there. | |
| - this is deliberately using RDFa. | |
| --> | |
| <div typeof="schema:Dataset" resource="doi:10.4242/cryptoZ.2017"> | |
| <span property="schema:name">Sightings of Levrogyrous Dahuts during Transalpine Migratory Periods</span> | |
| <span property="schema:author" typeof="schema:Person" resource="http://orcid.org/0000-0002-1731-5346"> | |
| <span property="schema:name">Robin Berjon</span> |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>CompositionUpdate</title> | |
| </head> | |
| <body> | |
| <input id="input"> | |
| <pre id="log"></pre> | |
| <script> |
| import React from 'react' | |
| import Portal from 'react-portal' | |
| class LinkBlock extends React.Component { | |
| constructor (props) { | |
| super(props) | |
| this.state = { | |
| href: this.props.node.data.get('href'), | |
| showingPopup: false, | |
| popup: null, |
This gist was automatically created by the JSON-LD Playground. You can see it loaded there by visiting: http://json-ld.org/playground#/gist/7f3121380e3e26500a78e63a2c74cdb1