Commit Graph
247 Commits
Author SHA1 Message Date
Dan AbramovandGitHub 5472c94996 Add Fiber Debugger (#8033)
* Build react-noop as a package

This lets us consume it from the debugger.

* Add instrumentation to Fiber

* Check in Fiber Debugger
2016-10-25 08:36:37 +01:00
Paul O’ShannessyandGitHub 9f8c3e366c Fix npm package builds (#7888)
* Ensure lib/ is packaged for react-test-renderer

* Run npm pack from right working directory

We were running this on the original packages not the compiled ones, resulting in missing files
2016-10-05 15:32:38 -07:00
Paul O’ShannessyandGitHub 993eae2139 Fix UMD bundles, making safe to use as required modules (#7840) 2016-10-03 15:49:10 -07:00
Christopher ChedeauandGitHub 09841b5f44 Restore coverage in Travis (#7628)
We disabled coverage in Travis because the implementation was crashing ( https://github.com/facebook/react/issues/6290 ). Since we upgraded to Jest 15, the entire coverage implementation is brand new so we should give it another try.
2016-09-02 14:23:58 -07:00
Paul O’ShannessyandGitHub 3dba71b8ea Add more specific link to react-addons-shallow-compare readme (#7608) 2016-08-31 15:53:30 -07:00
Sebastian MarkbågeandGitHub fa1708f118 Use aliasify everywhere instead of browserify-global-shim (#7476)
I already had to aliasify to have better control over the requires
so we might as well do it everywhere for consistency.

This probably makes it easier to rebase the rollup work too
because aliases seems to be how you solve this in that world.
2016-08-11 20:17:37 -07:00
Sebastian MarkbågeandGitHub 90c883e5d6 Require the isomorphic React instead of internals from renderers (#7473)
This is needed for flat builds. It also lets us get rid of a bunch
of special cases in the build scripts.

It also allow us to just copy the source files into React Native
instead of having to build first to resolve the special cases.
2016-08-11 18:56:55 -07:00
Sebastian MarkbågeandGitHub 390d72adfc Build React DOM Fiber package (#7173)
This builds a `react-dom-fiber.js` bundle which exposes ReactDOMFiber.
This allows early experiments with the new Fiber reconciler.

I also expose it in the npm package through `react-dom/fiber`.
2016-08-10 18:45:14 -07:00
Sebastian MarkbågeandGitHub 544ecbb919 Build renderers into their individual npm packages (#7168)
This copies modules into three separate packages instead of
putting it all in React.

The overlap in shared and between renderers gets duplicated.

This allows the isomorphic package to stay minimal. It can also
be used as a direct dependency without much risk.

This also allow us to ship versions to each renderer independently
and we can ship renderers without updating the main react package
dependency.
2016-08-10 18:17:49 -07:00
Sebastian MarkbågeandGitHub 4baa953e90 Include React itself in the list of shims (#7453)
Without this we end up bundling all of the isomorphic React into
the DOM bundle. This was fixed in #7168 too but I'll just do an
early fix to ensure that #7168 is purely an npm change.
2016-08-09 15:33:34 -07:00
Sebastian MarkbågeandGitHub 08707b0c2b Fix trailing build issues (#7450)
Use relative path for addons UMD shim module

Use explicit top level wrapper marker for top level elements
2016-08-09 12:52:15 -07:00
Sebastian MarkbågeandGitHub 63e1203674 Bundle DOM renderers into their individual UMD bundles (#7164)
* Cut out isomorphic dependencies from the renderers

These files reaches into isomorphic files.

The ReactElement functions are exposed on the React object anyway
so I can just use those instead.

I also found some files that are not shared that should be in
renderers shared.

* Found a few more shared dependencies

renderSubtreeIntoContainer is only used by the DOM renderer.
It's not an addon.

ReactClass isn't needed as a dependency since injection doesn't
happen anymore.

* Use a shim file to load addons' dependencies on DOM

By replacing this intermediate file we can do the lazy loading
without needing any lazy requires. This set up works with ES
modules.

We could also replace the globalShim thing with aliased files
instead for consistency.

* Bundle DOM renderers into their individual UMD bundles

Instead of exposing the entire DOM renderer on the react.js
package, I only expose CurrentOwner and ComponentTreeDevtool which
are currently the only two modules that share __state__ with the
renderers.

Then I package each renderer in its own package. That could allow
us to drop more server dependencies from the client package. It
will also allow us to ship fiber as a separate renderer.

Unminified DEV            after     before
react.js                  123kb     696kb
react-with-addons.js      227kb     774kb
react-dom.js              668kb     1kb
react-dom-server.js       638kb     1kb

Minified PROD             after     before
react.min.js               24kb     154kb
react-with-addons.min.js   37kb     166kb
react-dom.min.js          149kb     1kb
react-dom-server.min.js   144kb     1kb

The total size for react.min.js + react-dom.min.js is +19kb larger
because of the overlap between them right now. I'd like to see
what an optimizing compiler can do to this. Some of that is fbjs
stuff. There shouldn't need to be that much overlap so that's
something we can hunt. We should keep isomorphic absolutely
minimal so there's no reason for other React clones not to use it.
There will be less overlap with Fiber.

However, another strategy that we could do is package the
isomorphic package into each renderer bundle and conditionally
initialize it if it hasn't already been initialized. That way
you only pay an overlap tax when there are two renderers on the
page but not without it. It's also easier to just pull in one
package. The downside is the versioning stuff that the separate
npm package would solve. That applies to CDNs as well.

ReactWithAddons is a bit weird because it is packaged into the
isomorphic package but has a bunch of DOM dependencies. So we have
to load them lazily since the DOM package gets initialized after.
2016-08-09 12:39:03 -07:00
Dustan KastenandPaul O’Shannessy e7c6417da2 ReactTestRenderer package (#7362) 2016-07-28 21:39:05 -07:00
Dan AbramovandGitHub 573ad5d3e4 Eagerly evaluate inline requires in Jest (#7245)
* Eagerly evaluate inline requires in Jest

I inlined some requires in #7188 to fix the build size regression.
However this caused an issue with Jest due to it resetting module registry between tests.

This is a temporary fix to #7240.
It should be reverted as part of #7178.

* Make the hack work in all environments
2016-07-16 20:51:25 +01:00
Marshall BowersandPaul O’Shannessy 6031037eee Gulp: lint, flow, and version-check (#7174)
* Add plugin loading for gulp

* Convert `lint` task to gulp

* Convert `flow` task to gulp

* Convert `version-check` task to gulp

* Add missing semicolons
2016-07-05 13:30:09 -07:00
Dan Abramov 4e9d1fad33 Update jest bin command 2016-05-25 21:49:32 +01:00
Dmitrii AbramovandDan Abramov 2437b01316 ReactClassEquivalence 2016-05-25 21:49:31 +01:00
Dan Abramov 820c0f6836 Merge pull request #6647 from gaearon/bye-bye-reactperf
Replace ReactPerf with new implementation
2016-05-05 02:57:13 +01:00
Paul O’Shannessy 1dc7dac68d Setup grunt flow task and run on travis (#6684) 2016-05-03 18:16:38 -07:00
Paul O’Shannessy 281e014756 grunt jest tasks shouldn't use watchman (#6675) 2016-05-03 14:39:11 -07:00
Paul O’Shannessy 6bcac27f2f Ensure babelrc gets added to zipfile too (#6688) 2016-05-03 13:58:06 -07:00
Dan Abramov 818615ee7c Rename the new ReactPerfAnalysis to ReactPerf 2016-05-03 14:21:29 +01:00
Dan Abramov b234c684aa Add new ReactPerf 2016-04-28 20:45:57 +01:00
Paul O’Shannessy 52dd6284a9 Ensure babelrc file gets packaged for starter kit (#6617) 2016-04-28 00:24:58 -07:00
cpojer aaf4aacf2f Update Jest’s grunt task. 2016-04-28 16:08:20 +09:00
cpojer 412c261ca2 Update to Jest 12. Codemod to new Jest APIs. 2016-04-28 14:54:57 +09:00
Sebastian Markbage e7b3efb987 Ensure react-native-renderer package gets copied 2016-04-20 03:35:31 +01:00
Sebastian Markbage 3a2138d04f Build an dedicated npm package for react-native-renderer 2016-04-20 03:35:30 +01:00
Paul O’Shannessy af2c9fac21 Remove jsx task & jsx-internal script
These haven't been used in a long time so it's time to get rid of them.
2016-04-05 10:18:42 -07:00
Paul O’Shannessy a308709d14 Make Browserify-specific modules to remove DOM dependencies from npm package 2016-03-24 15:28:52 -07:00
Christoffer Sawicki 35380f616b Use loose-envify instead of envify
This reduces the number of transitive dependencies and decreases the build time (by ~6% on my machine).
2016-03-21 20:18:17 +01:00
Paul O’Shannessy ff3fccf40a Clean up ununsed devDeps
Also removed object-assign. We only support building with node v4+ which has Object.assign.
2016-01-22 10:17:30 -08:00
jim 92f9c7a31d Removed cloneWithProps addon. 2016-01-15 17:17:36 -08:00
Rick Beerendonk 23ed4ec4e2 Year-agnostic copyright message, like React Native uses, to prevent the need for yearly changes. 2015-12-29 20:20:32 +01:00
Paul O’Shannessy 050420324b Ensure build directory works when running jest:coverage on its own 2015-12-22 14:36:27 -08:00
Paul O’Shannessy 4115ab6192 Remove coverage options from package.json
They don't provide any value and since one of them isn't a valid config usage,
it blurs the line. Instead just store these pieces in the tasks and write them
to the temp config.
2015-12-22 11:14:44 -08:00
Paul O’Shannessy eb9622b01e Split jest task into two
This ensures that we don't make jest do the additional tracking it needs to make coverage work.
2015-12-22 10:25:34 -08:00
John-David Dalton 3c85d1735d Add coveralls. 2015-12-22 06:48:33 -06:00
zwhitchcox 81fa5478df Remove dead code
This isn't used anywhere in React
2015-12-04 18:28:37 -05:00
Paul O’Shannessy 31049d4b61 Make sure react-dom-server is shipped in release process
Also removed some duplicated code to simplify a bit
2015-11-18 13:08:44 -08:00
Paul O’Shannessy eb5598e363 Merge pull request #5381 from kevinrobinson/react-dom-server-package
Add additional secret property to build artifact for react-dom-server
2015-11-17 16:48:08 -08:00
Paul O’Shannessy b6349ed4ac Ensure license and patents files are packaged for npm 2015-11-09 12:47:22 -08:00
Paul O’Shannessy 4c76b5e483 Merge pull request #5396 from zpao/packagejsons
Improve npm packages' metadata
2015-11-04 21:29:35 -08:00
Paul O’Shannessy 0a3e7c1090 Generate better readmes for addons npm packages 2015-11-04 21:25:28 -08:00
chico cdaa48e719 review fixes 2015-11-05 05:11:39 +03:00
chico 96af5176c4 remove eslint-disable when possible and update eslint version 2015-11-05 05:11:39 +03:00
Kevin Robinson 9259e24012 Add additional secret property and build for react-dom-server
Update eslintrc, travis build and add task to Gruntfile
2015-11-03 16:39:58 -05:00
Thomas Broadley 6224b1431d 'grunt lint' now works on Windows 2015-10-30 06:43:43 +09:00
Paul O’Shannessy d9efb0525f Stop generating gh-pages during release, update message 2015-10-13 09:37:32 -07:00
Jim 598682f06e React -> ReactDOM for render() and findDOMNode() 2015-10-05 17:46:58 -07:00