cf-component-code
Advanced tools
Comparing version 1.0.0 to 1.0.1
"use strict"; | ||
exports.__esModule = true; | ||
var React = require('react'); | ||
var _react = require("react"); | ||
function Code(props) { | ||
return React.createElement( | ||
"code", | ||
{ className: "cf-code" }, | ||
props.children | ||
); | ||
} | ||
var _react2 = _interopRequireDefault(_react); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } | ||
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } | ||
var Code = function (_React$Component) { | ||
_inherits(Code, _React$Component); | ||
function Code() { | ||
_classCallCheck(this, Code); | ||
return _possibleConstructorReturn(this, _React$Component.apply(this, arguments)); | ||
} | ||
Code.prototype.render = function render() { | ||
return _react2.default.createElement( | ||
"code", | ||
{ className: "cf-code" }, | ||
this.props.children | ||
); | ||
}; | ||
return Code; | ||
}(_react2.default.Component); | ||
exports.default = Code; | ||
module.exports = Code; |
'use strict'; | ||
exports.__esModule = true; | ||
var React = require('react'); | ||
var Code = require('./Code'); | ||
var _react = require('react'); | ||
function CodeBlock(props) { | ||
return React.createElement( | ||
'pre', | ||
{ className: 'cf-code__block' }, | ||
React.createElement( | ||
Code, | ||
null, | ||
props.children | ||
) | ||
); | ||
} | ||
var _react2 = _interopRequireDefault(_react); | ||
var _Code = require('./Code'); | ||
var _Code2 = _interopRequireDefault(_Code); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } | ||
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; } | ||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; } | ||
var CodeBlock = function (_React$Component) { | ||
_inherits(CodeBlock, _React$Component); | ||
function CodeBlock() { | ||
_classCallCheck(this, CodeBlock); | ||
return _possibleConstructorReturn(this, _React$Component.apply(this, arguments)); | ||
} | ||
CodeBlock.prototype.render = function render() { | ||
return _react2.default.createElement( | ||
'pre', | ||
{ className: 'cf-code__block' }, | ||
_react2.default.createElement( | ||
_Code2.default, | ||
null, | ||
this.props.children | ||
) | ||
); | ||
}; | ||
return CodeBlock; | ||
}(_react2.default.Component); | ||
exports.default = CodeBlock; | ||
module.exports = CodeBlock; |
'use strict'; | ||
exports.__esModule = true; | ||
exports.CodeBlock = exports.Code = undefined; | ||
var _Code2 = require('./Code'); | ||
var _Code3 = _interopRequireDefault(_Code2); | ||
var _CodeBlock2 = require('./CodeBlock'); | ||
var _CodeBlock3 = _interopRequireDefault(_CodeBlock2); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
exports.Code = _Code3.default; | ||
exports.CodeBlock = _CodeBlock3.default; | ||
exports.Code = require('./Code'); | ||
exports.CodeBlock = require('./CodeBlock'); |
{ | ||
"name": "cf-component-code", | ||
"description": "CloudFlare Code Component", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"main": "lib/index.js", | ||
"scripts": { | ||
"build": "babel src -d lib", | ||
"format": "jsfmt -w *.js src/ test/", | ||
"lint": "eslint *.js src/ test/", | ||
"prepublish": "npm run build", | ||
"test": "karma start" | ||
}, | ||
"author": "James Kyle <jkyle@cloudflare.com>", | ||
@@ -19,26 +12,4 @@ "license": "BSD-3-Clause", | ||
"devDependencies": { | ||
"babel-cli": "^6.1.1", | ||
"babel-core": "^6.0.20", | ||
"babel-preset-cf": "^1.2.0", | ||
"babelify": "^7.2.0", | ||
"browserify-istanbul": "^0.2.1", | ||
"chai": "^3.4.1", | ||
"defined": "^1.0.0", | ||
"eslint": "^1.8.0", | ||
"jsfmt": "^0.5.2", | ||
"karma": "^0.13.15", | ||
"karma-beep-reporter": "^0.1.4", | ||
"karma-browserify": "^4.4.0", | ||
"karma-chrome-launcher": "^0.2.1", | ||
"karma-coverage": "^0.5.3", | ||
"karma-firefox-launcher": "^0.1.6", | ||
"karma-mocha": "^0.2.0", | ||
"karma-mocha-reporter": "^1.1.1", | ||
"karma-safari-launcher": "^0.1.1", | ||
"karma-sauce-launcher": "^0.3.0", | ||
"karma-tape-reporter": "^1.0.3", | ||
"minimist": "^1.2.0", | ||
"mocha": "^2.3.3", | ||
"react-dom": "^0.14.2" | ||
} | ||
} |
@@ -14,4 +14,4 @@ # cf-component-code | ||
```js | ||
import React from 'react'; | ||
import {Code, CodeBlock} from 'cf-component-code'; | ||
const React = require('react'); | ||
const {Code, CodeBlock} = require('cf-component-code'); | ||
@@ -18,0 +18,0 @@ export default class Application extends React.Component { |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1
1347
6
25