Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

graphql-syntax-highlighter-react

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

graphql-syntax-highlighter-react - npm Package Compare versions

Comparing version 0.1.0 to 0.2.0

.npmignore

30

dist/GraphqlCodeBlock.js

@@ -31,17 +31,17 @@ 'use strict';

var GraphqlCodBlock = function (_Component) {
_inherits(GraphqlCodBlock, _Component);
var GraphqlCodeBlock = function (_Component) {
_inherits(GraphqlCodeBlock, _Component);
function GraphqlCodBlock() {
_classCallCheck(this, GraphqlCodBlock);
function GraphqlCodeBlock() {
_classCallCheck(this, GraphqlCodeBlock);
return _possibleConstructorReturn(this, (GraphqlCodBlock.__proto__ || Object.getPrototypeOf(GraphqlCodBlock)).apply(this, arguments));
return _possibleConstructorReturn(this, (GraphqlCodeBlock.__proto__ || Object.getPrototypeOf(GraphqlCodeBlock)).apply(this, arguments));
}
_createClass(GraphqlCodBlock, [{
_createClass(GraphqlCodeBlock, [{
key: 'render',
value: function render() {
var _props = this.props;
var className = _props.className;
var queryBody = _props.queryBody;
var _props = this.props,
className = _props.className,
queryBody = _props.queryBody;

@@ -59,5 +59,5 @@ var formatted = (0, _graphql.print)((0, _graphql.parse)(queryBody));

}, function (stream, state, style) {
var _sourceText = stream._sourceText;
var _start = stream._start;
var _pos = stream._pos;
var _sourceText = stream._sourceText,
_start = stream._start,
_pos = stream._pos;

@@ -93,9 +93,9 @@ if (rowKeys[rowKeys.length - 1] !== _sourceText) {

return GraphqlCodBlock;
return GraphqlCodeBlock;
}(_react.Component);
GraphqlCodBlock.propTypes = {
GraphqlCodeBlock.propTypes = {
queryBody: _react.PropTypes.string,
className: _react.PropTypes.string
};
exports.default = GraphqlCodBlock;
exports.default = GraphqlCodeBlock;

@@ -7,3 +7,3 @@ 'use strict';

var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

@@ -136,3 +136,3 @@ var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();

value: function match(pattern) {
var consume = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1];
var consume = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
var caseFold = arguments[2];

@@ -139,0 +139,0 @@

@@ -50,6 +50,6 @@ 'use strict';

function getToken(stream, state, options) {
var LexRules = options.LexRules;
var ParseRules = options.ParseRules;
var eatWhitespace = options.eatWhitespace;
var editorConfig = options.editorConfig;
var LexRules = options.LexRules,
ParseRules = options.ParseRules,
eatWhitespace = options.eatWhitespace,
editorConfig = options.editorConfig;

@@ -56,0 +56,0 @@ if (state.needsAdvance) {

@@ -14,3 +14,3 @@ 'use strict';

var isIgnored = exports.isIgnored = function isIgnored(ch) {
return ch === ' ' || ch === '\t' || ch === ',' || ch === '\n' || ch === '\r' || ch === '';
return ch === ' ' || ch === '\t' || ch === ',' || ch === '\n' || ch === '\r' || ch === '\uFEFF';
};

@@ -17,0 +17,0 @@

{
"name": "graphql-syntax-highlighter-react",
"version": "0.1.0",
"version": "0.2.0",
"description": "A React component for highlighting GraphQL syntax.",

@@ -8,3 +8,3 @@ "main": "dist/index.js",

"build": "babel ./src --ignore test --out-dir ./dist",
"prepublish": "npm run build",
"prepare": "npm run build",
"test": "mocha --compilers js:babel-core/register --reporter spec --full-trace 'src/**/*.test.js'"

@@ -29,9 +29,11 @@ },

"babel-cli": "^6.11.4",
"babel-plugin-transform-class-properties": "^6.11.5",
"babel-plugin-transform-exponentiation-operator": "^6.8.0",
"babel-plugin-transform-class-properties": "^6.24.1",
"babel-plugin-transform-exponentiation-operator": "^6.24.1",
"babel-preset-es2015": "^6.13.2",
"babel-preset-react": "^6.11.1"
},
"peerDependencies": {
"react": "^15.3.1"
},
"dependencies": {
"react": "15.3.1",
"graphql": "^0.7.0"

@@ -41,11 +43,2 @@ },

"homepage": "https://github.com/daniman/graphql-syntax-highlighter-react#readme",
"_id": "graphql-syntax-highlighter-react@0.0.17",
"_shasum": "5aca065735a69858fc7e8600880be79d8b298623",
"_from": "graphql-syntax-highlighter-react@0.0.17",
"_npmVersion": "2.15.8",
"_nodeVersion": "4.4.7",
"_npmUser": {
"name": "daniman",
"email": "daniman0808@gmail.com"
},
"dist": {

@@ -61,9 +54,3 @@ "shasum": "5aca065735a69858fc7e8600880be79d8b298623",

],
"_npmOperationalInternal": {
"host": "packages-12-west.internal.npmjs.com",
"tmp": "tmp/graphql-syntax-highlighter-react-0.0.17.tgz_1473987198657_0.28812974668107927"
},
"directories": {},
"_resolved": "https://registry.npmjs.org/graphql-syntax-highlighter-react/-/graphql-syntax-highlighter-react-0.0.17.tgz",
"readme": "ERROR: No README data found!"
"directories": {}
}

@@ -7,3 +7,3 @@ import { LexRules, ParseRules, isIgnored } from './utils/Rules.js';

export default class GraphqlCodBlock extends Component {
export default class GraphqlCodeBlock extends Component {
static propTypes = {

@@ -10,0 +10,0 @@ queryBody: PropTypes.string,

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