Commit Graph
73 Commits
Author SHA1 Message Date
Jeff Morrison 9c2b9b1eb6 Merge pull request #970 from syranide/jsxws
Normalize whitespace for transformed JSX code
2014-04-04 10:20:43 -07:00
Paul O’Shannessy 0617696ae4 Merge pull request #1251 from davidxi/patch-1
Update jasmine-support.js
2014-04-03 18:41:59 -07:00
Ben Alpert e6c93f9246 Add optional harmony support to browser transform
This mirrors the react-tools API; it doesn't include support (yet) for transforming `<script type="text/jsx">` blocks with the ES6 transforms, mostly because I don't have a good API in mind there.

Test Plan:
Ran

    JSXTransformer.transform("var two = () => 2;", {harmony: true}).code

in Chrome's dev console and got back some ES5 code.
2014-03-28 18:26:20 -10:00
Paul O’Shannessy 8d495f3b6e Revert "Merge pull request #1234 from RReverser/pure-cjs"
This reverts commit 7987e6a51d, reversing
changes made to d88d479685.
2014-03-18 11:25:21 -07:00
Ben Newman 7987e6a51d Merge pull request #1234 from RReverser/pure-cjs
Switched from browserify to pure-cjs bundler.
2014-03-18 12:04:58 -04:00
Paul O’Shannessy d88d479685 Merge pull request #1193 from spicyj/jsx-polygon
Add polygon tag to transform
2014-03-17 10:07:23 -07:00
davidxi 29abe53924 Update jasmine-support.js
fix typo in multiple error messages.
2014-03-12 14:39:14 -04:00
Andreas Svensson 60d7a02d44 Normalize whitespace for transformed JSX code 2014-03-12 10:03:16 +01:00
Andreas Svensson 280ff2e5a7 Unbreak JSX comment comma fix 2014-03-11 00:31:59 +01:00
Ingvar Stepanyan 3171436d97 Switched from browserify to pure-cjs bundler.
Optimizations and fix for JSXTransformer build.
Dropped dependency on emulation of Node.js native modules.
Added deamdify step for JSXTransformer build.
2014-03-08 16:33:58 +02:00
Andreas Svensson aa70419f9d Fix empty JSX expressions sometimes emitting erroneous commas 2014-03-06 13:01:03 +01:00
Ben Alpert 42444f6bb9 Add polygon tag to transform
Fixes #1144.
2014-02-27 12:32:24 -08:00
Paul O’Shannessy 7b773a6b3d make <hasOwnProperty/> transform correctly 2014-02-24 18:03:02 -08:00
Ben Alpert 472be09ff6 Make JSX transform not break on 'constructor' attr 2014-02-20 21:44:58 -08:00
Paul O’Shannessy 8a47813baa Update copyrights for 2014.
grep -rl 'Copyright 2013 Facebook' static_upstream | xargs perl -pi -w -e s/Copyright 2013 Facebook/Copyright 2013-2014 Facebook/g;'

Not going to check in a script to do this since it will just change every year.
Closes #1006
2014-02-18 17:06:43 -08:00
Ben Alpert 5795376961 Strip calls to warning() in __DEV__
Fixes #1120.
2014-02-17 19:01:45 -08:00
JeffMo adcbf0806c Sync out transforms from fb internal 2014-02-15 12:35:32 -08:00
Ben Alpert 89bcecc76f Disable source maps when defineProperty is missing
Fixes #1053.
2014-02-11 00:10:06 -08:00
Ben Newman 77c53dd5d4 Revert "More optimizations and fix for JSXTransformer build"
This reverts commit f1b7db9aef.
2014-02-03 19:05:15 -05:00
Ingvar Stepanyan f1b7db9aef More optimizations and fix for JSXTransformer build
* Dropped dependency on emulation of Node.js native modules.
* Added deamdify step for JSXTransformer build.
2014-01-31 21:53:08 +02:00
Andreas Svensson c16b5659a0 Implement stricter whitespace rules 2014-01-22 21:00:10 +01:00
Fabio M. Costa de7a92afa7 Updating error message to also show part of the code, making it easier to find the error 2014-01-20 11:57:35 -08:00
Fabio M. Costa d829d1ab9b Adding current page's url for inline code and code improvement 2014-01-20 11:57:34 -08:00
Fabio M. Costa b1a949ed45 Adds the filename to JSXTransform error message, making it easier to debug JSX syntax errors. 2014-01-20 11:55:17 -08:00
cpojer 8dbc530d1c Add --harmony option to jsx. 2014-01-09 15:21:48 -08:00
Jeff Morrison 33fe8eebda Merge pull request #799 from spicyj/display-name
Add display name in more cases
2014-01-07 12:58:23 -08:00
Ben Alpert f0fdabae7b Add display name in more cases 2014-01-07 09:36:47 -08:00
Christopher Chedeau 9454282bfc Merge pull request #819 from mtharrison/add-more-svg-tags
Added support for 4 extra SVG tags
2014-01-06 15:44:15 -08:00
Ben Newman b7b4bcfd2e Merge pull request #764 from spicyj/browser-source-maps
Add source map support to browser transformer.
2014-01-06 14:38:00 -08:00
Matt Harrison c4d918aca0 Added support for 4 extra SVG tags: stop, defs, linearGradient, radialGradient 2014-01-05 11:17:04 +00:00
Nick Thompson d270e2b1c7 Don't add displayName in transform if already defined
This ensures we don't add displayName in the transform if it's already been
defined. This is especially important when in strict mode, where duplicate
properties in an object is an exception.
2014-01-03 16:07:10 -08:00
Ben Alpert 7675611e5f Add source map support to browser transformer 2013-12-31 12:03:34 -07:00
Ben Newman f3a6775098 Upgrade recast dev dependency to v0.5.6.
Paving the way for source maps.
2013-12-17 14:50:36 -05:00
Ben Alpert 277abbfe7b Fix lint error (unused variable) 2013-12-09 12:29:03 -08:00
petehunt 90e2258791 response to code review 2013-12-06 11:56:30 -08:00
petehunt 5466d0a063 first work: __DEV__
fix invariant

Get browserify working

remove dead code elimination step since it is not needed due to minifier

use industry standard NODE_ENV
2013-12-06 11:56:29 -08:00
cpojer 31359e9962 Add more useful ES6 transforms to jsx-internal. 2013-12-05 10:20:24 -08:00
Ben Alpert 3a75d70501 Allow running one spec/suite in the web interface
This is the proper way to make it filter the spec list:

https://github.com/pivotal/jasmine/blob/1_3_x/spec/runner.html

I submitted the jasmine-jsreporter change as a pull request here:

https://github.com/detro/jasmine-jsreporter/pull/2

Fixes #563.
2013-11-24 00:53:29 -05:00
Paul O’Shannessy b2507066b6 Don't call utils.traverse in transform
Accidental change we missed in review of #495.
2013-11-20 15:36:54 -08:00
Andreas Svensson a39b8fda70 utils.* is now used everywhere 2013-11-15 11:17:24 +01:00
Ben Newman b61eacd3c5 Explicitly require the assert module in vendor/constants.js. 2013-11-14 13:48:08 -05:00
Ben Newman da717977ed Better comments for vendor/constants.js. 2013-11-13 15:33:10 -05:00
Ben Newman 2b763fc452 Rewrite vendor/constants.js to use require("ast-types").traverse.
Most notably, this new style of transformation gives us access to
this.parent.node, which allows us to avoid replacing identifiers that are
not actually free variables, such as member expression properties.

Closes #496.
2013-11-13 15:33:10 -05:00
Andreas Svensson 595b482478 JSXTransformer now supports IE8 2013-11-08 23:04:43 +01:00
Thomas Aylott 7bbf6cbfd1 browser support for jasmine-support 2013-11-06 15:30:51 -05:00
Thomas Aylott f65f7b3bbd IE8 support in jasmine-support 2013-11-06 15:30:50 -05:00
Thomas Aylott 284d8d67bd Upgrade to the latest version of jasmine
Necessary for IE8 support
2013-11-06 15:30:50 -05:00
Thomas Aylott 3df6942cde SauceLabs Browser testing via Travis 2013-11-06 15:30:50 -05:00
JeffMo a4f8ad1bb0 Switch utility function calls -> namespaced calls 2013-10-31 13:45:16 -07:00
SanderSpies 6839704c4b #JSX => #jsx 2013-10-15 19:11:19 +02:00