var path = require("path");
var express = require("express");
var app = express();
require('node-jsx').install({ extension: '.jsx' })
require('source-map-support').install();
var React = require("react");
var PageHome = React.createFactory(require("../components/PageHome/PageHome.jsx"));
In theory requiring the jsx should transform it but I am getting an error:
A very simple setup:
In theory requiring the
jsx
should transform it but I am getting an error:The
jsx
should be fine though:The dependencies are minimal
Poking into
node-jsx
it seems like the require extensions are not being called at all. https://github.com/petehunt/node-jsx/blob/master/index.js#L17I am really not sure what's going on. Any thoughts?
$ node --version v0.12.0 $ npm -version 2.5.1