Skip to content

Instantly share code, notes, and snippets.

@sawyerh
Last active March 7, 2016 18:12
Show Gist options
  • Save sawyerh/8f55124e50f572bd481d to your computer and use it in GitHub Desktop.
Save sawyerh/8f55124e50f572bd481d to your computer and use it in GitHub Desktop.
{
"presets": [
"react",
"es2015"
]
}
● Runtime Error
SyntaxError: Unexpected token <
at eval (native)
at Object.<anonymous> (/Users/sawyer/Sites/Siteleaf/app/assets/js/main-component.jsx:3:23)
at Object.<anonymous> (/Users/sawyer/Sites/Siteleaf/app/assets/js/__tests__/main-component-test.js:4:21)
at emitTwo (events.js:87:13)
at process.emit (events.js:172:7)
at handleMessage (internal/child_process.js:686:10)
at Pipe.channel.onread (internal/child_process.js:440:11)
'use strict';
jest.dontMock('../main-component');
var MainComponent = require('../main-component');
describe('Metadata String Field', () => {
it('should include nested component', () => {
// Dummy test to just get things working...
expect(true).toBe(true);
});
});
"use strict";
var React = require('react');
var NestedComponent = require('app-js/nested-component');
var MainComponent = React.createClass({
render() {
return (
<div>
<NestedComponent />
<textarea />
</div>
)
}
});
module.exports = MainComponent;
"use strict";
var React = require('react');
var NestedComponent = React.createClass({
render() {
return (
<div>
<strong>Hello world</strong>
</div>
)
}
});
module.exports = NestedComponent;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment