Socket
Socket
Sign inDemoInstall

millan

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

millan - npm Package Compare versions

Comparing version 2.2.2 to 2.3.0

dist/browser/millan.graphql.js

3

dist/types/helpers/types.d.ts

@@ -12,2 +12,5 @@ import { IToken, IRecognitionException, CstNode, TokenType, IRecognizerContext } from 'chevrotain';

}
export interface CstNodeMap {
[key: string]: CstNode[];
}
export interface ISemanticError extends Pick<IRecognitionException, Exclude<keyof IRecognitionException, 'resyncedTokens' | 'context'>> {

@@ -14,0 +17,0 @@ resyncedTokens?: IToken[];

@@ -8,2 +8,5 @@ export * from './sparql/BaseSparqlParser';

export * from './shacl/ShaclParser';
export * from './graphql/BaseGraphQlParser';
export * from './graphql/StandardGraphQlParser';
export * from './graphql/StardogGraphQlParser';
export * from './helpers/cst';

@@ -16,5 +19,6 @@ export * from './helpers/types';

declare const shaclTokens: any;
declare const graphQlTokens: any;
import { keywords as sparqlKeywords } from './sparql/keywords';
import { terminals as sparqlTerminals } from './sparql/terminals';
import * as matchers from './helpers/matchers';
export { sparqlTokens, turtleTokens, smsTokens, srsTokens, shaclTokens, sparqlKeywords, sparqlTerminals, matchers, };
export { sparqlTokens, turtleTokens, smsTokens, srsTokens, shaclTokens, graphQlTokens, sparqlKeywords, sparqlTerminals, matchers, };

11

package.json
{
"name": "millan",
"version": "2.2.2",
"version": "2.3.0",
"description": "The Stardog Whisperer (error-tolerant parsers for languages used with Stardog)",

@@ -15,5 +15,7 @@ "keywords": [

"rules",
"shacl"
"shacl",
"graphql"
],
"main": "dist/millan.js",
"browser": "dist/browser/millan.js",
"types": "dist/types/index.d.ts",

@@ -68,2 +70,3 @@ "files": [

"prettier": "^1.12.1",
"rimraf": "^2.6.3",
"terser-webpack-plugin": "^1.1.0",

@@ -90,6 +93,6 @@ "ts-jest": "^24.0.2",

"pack": "webpack",
"build": "run-s test pack types",
"build": "rimraf ./dist && run-s test pack types",
"dev": "webpack -w",
"format": "prettier 'src/**/*.[tj]s' -- write",
"docs": "typedoc --exclude '__tests__/**/*' --target ES5 --mode file --out ./docs ./src",
"docs": "rimraf ./docs && typedoc --exclude '__tests__/**/*' --target ES5 --mode file --out ./docs ./src",
"types": "tsc --emitDeclarationOnly"

@@ -96,0 +99,0 @@ },

@@ -7,3 +7,3 @@ # Millan

[Stardog Mapping Syntax 2 (SMS)](https://www.stardog.com/docs/#_stardog_mapping_syntax_2),
[Stardog Rules Syntax](https://www.stardog.com/docs/#_stardog_rules_syntax)), and the Turtle serialization of [SHACL](https://www.w3.org/TR/shacl/).
[Stardog Rules Syntax](https://www.stardog.com/docs/#_stardog_rules_syntax), the Turtle serialization of [SHACL](https://www.w3.org/TR/shacl/), and [GraphQL](https://graphql.github.io/graphql-spec/)).

@@ -18,5 +18,6 @@ ## Features

- Error-tolerant parsing for the Turtle serialization of the W3C Shapes Constraints Language (SHACL)
- Error-tolerant parsing for GraphQL (both the Facebook standard and with [Stardog's GraphQL extensions](https://www.stardog.com/docs/#_graphql_queries))
- Exported token matchers (regular expressions) and token sets for all of the
above languages
- Universally usable (both in nodejs and the browser)
- Universally usable (both in nodejs and the browser), either as a single bundle or as only the specific parts you need
- Tested against W3C test suites

@@ -44,15 +45,30 @@ - Small and fast

const millan = require('millan');
// or, if you only need some part of millan (e.g., only _one_ of the parsers):
const graphql = require('millan/standalone/millan.graphql');
```
In the browser:
As an ES module:
```javascript
import * as millan from 'millan';
// or, if you only need some part of millan (e.g., only _one_ of the parsers):
import { StardogSparqlParser } from 'millan/standalone/millan.sparql';
```
In the browser, importing everything at once:
```html
<script src="path/to/millan/index.umd.min.js"></script>
<script src="path/to/millan/millan.js"></script>
```
As an ES module:
In the browser, importing only what is needed:
```javascript
import * as millan from 'millan';
```html
<!-- Here, we first load any shared chunks needed by 'sms' (as indicated by the filename), then the SMS-related Javacript only -->
<script src="path/to/millan/browser/millan.vendors~graphql~shacl~sms~sparql~srs~turtle.js"></script>
<script src="path/to/millan/browser/millan.sms.js"></script>
```
When used in the browser via `script` tags, the API will be exposed on a global `millan` variable.
## Basic Usage

@@ -59,0 +75,0 @@

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc