- Possibly breaking change render_component now accepts a
request_headerskeyword argument. There are some edge-cases where this may break down-stream code. If you are overriding part of the render pipeline, you may need to ensure that you are using**kwargsto read and/or pass wildcard arguments. (Ben Ilegbodu) markfinger#64 - [Documentation] Fix outdated link to server.js (Jonathan Cox) markfinger#60
- [Examples] missing babel-preset-es2015 in package.json in Tornado-example (付雨帆) markfinger#59
- [Examples] Added missing dependency on babel-preset-es2015 (Rune Juhl Jacobsen) markfinger#56
- [Examples] Added es6 compiler plugin to .bablerc in basic_rendering (Pringels) markfinger#55
- Breaking change The base renderer's init no longer accepts the RENDER_URL setting as an argument. The url is now resolved during calls, rather than initialisation.
- When used in companion with Django, settings will now be dynamically fetched rather than bound on initialisation. This enables a codebase to be more easily controlled from a test suite
- Updated docs regarding front-end integration
- Removed the webpack integration. While it can be initially convenient, it tends to introduce more problems than it solves. The repo contains an example illustrating how to implement self-mounting components which provide similar functionality to the former webpack integration.
- Replaced the js-host dependency with an externally-managed render server.
- Added a
rendererhook onrender_component. Enabling you to override the default which assumes render-react
- Fixed a potential path issue in config files
- Replaced the webpack-service dependency with webpack-wrapper.
- Boosting render performance by using a dedicated render server.
- Added a new setting, DJANGO_REACT['RENDERER'], which is a string denoting an import path to a
callable object which returns a on object with a
rendermethod. By default it points to the new render server, 'django_react.render_server.ReactRenderServer'. The legacy renderer is useable by setting DJANGO_REACT['RENDERER'] = 'django_react.renderer.ReactRenderer'.
- Changed
django_react.exceptions.ReactComponentMissingSourceAttributetodjango_react.exceptions.ReactComponentMissingSource django_react.react.renderis nowdjango_react.render_component- Updated the django-webpack dependency to 2.0.0
django_react.models.ReactBundleis nowdjango_react.ReactBundledjango_react.models.ReactComponentis nowdjango_react.ReactComponent- The Python<->JS bridge used to render components now relies on a
--serialized-props-fileargument, formerly it was--serialized-props. - Switched the JSX loader to a fork which improves the debug information provided during error handling
- The NODE_ENV environment setting is now controlled by the
DJANGO_REACT['DEBUG']setting. Activating it will provides some improvements to the rendering performance.
- Renamed
django_react.exceptions.PropSerialisationErrortodjango_react.exceptions.PropSerializationError. - Rolled the bundling functionality out into a more easily overridable interface. You can now define a
bundleattribute onReactComponentinheritors which should be an extendeddjango_webpack.models.WebpackBundle. - Renamed the following attributes on
ReactComponent:entryis nowsourcelibraryis nowvariable
- Renamed the
get_librarymethod onReactComponenttoget_variable - Removed the following methods on
ReactComponent:get_serialised_props_hashget_component_idget_react_variableget_component_namehas_props
- The render_* methods now use standard Django templates where possible.
- Removed the
render_to_stringandrender_to_static_markupmethods fromdjango_react.react. In their place, usedjango_react.react.render. - The react external can now be configured on a per-bundle basis, or globally by using the
DJANGO_REACT['REACT_EXTERNAL']setting. - Updated django-node and django-webpack dependencies to the latest.
- Added a test suite and harness.
- Added basic documentation.
- Fixed a bug where errors caused during a component's prop serialization could silently fail.
- Excised the bundling tooling into a standalone app,
django_webpack - Renamed
SerialisationExceptiontoPropSerializationError. - Renamed
RenderExceptiontoRenderingError. - Renamed the
django_react.utilsmodule todjango_react.react. ReactComponent.renderis nowReactComponent.render_to_stringReactComponent.render_staticis nowReactComponent.render_to_static_markupReactComponent.get_component_variableis nowReactComponent.get_library.- Moved the Webpack configuration into the ReactComponent class.
django_react.exceptions.ReactComponentSourceFileNotFoundis nowdjango_react.exceptions.SourceFileNotFounddjango_react.exceptions.ReactComponentRenderToStringExceptionis nowdjango_react.exceptions.RenderExceptiondjango_react.exceptions.ReactComponentBundleExceptionis nowdjango_react.exceptions.BundleExceptiondjango_react.models.ReactComponentnow has additional methods:generate_path_to_bundled_source,write_bundled_source_file,generate_bundled_source_file,get_rel_path_to_bundled_source, andget_url_to_bundled_source.django_react.utils.bundleno longer accepts aReactComponentas an argument, it now takesentryandlibrary.django_react.utils.renderno longer accepts aReactComponentas an argument, it now takespath_to_source,serialised_props, andto_static_markup.django_react/render.jsno longer accepts the--path-to-componentargument, instead it takes--path-to-source.
- Replaced the post-install step in setup.py with django-node's dependency and package resolver.
- Initial release