* Proper typings
* Don't run eslint for type definitions
* Make less strict and auto infer
* Add back Routes renderFn
* Remove console.log
* Switch to data-prefetch
The prefetch attribute is not an attribute on anchor elements. The preferred way to do custom attributes is using data-* attributes or custom web elements.
When using anchor attributes the only potential candidate would be rel="prefetch", but that is not enabled for anchor elements (only link elements):
https://developer.mozilla.org/en-US/docs/Web/HTTP/Link_prefetching_FAQ
* Format
* Fix inverted option
* Format
* Bump versions within major range
* Add missing configuration
This is a dependency from eslint-config-react-tools but not listed in the dependencies of that package.
* Use browsers configuration from project
This removes the hardcoded browserlists by injecting them from the root path.
This is a "sorta breaking" change, as it changes the defaults from:
- >1%,
- last 4 versions,
- Firefox ESR,
- not ie < 9
To:
- > 0.5%
- last 2 versions
- Firefox ESR
- not dead
Since this is also a bug, it will be released with the minor release. Adding `browserslist` to your package.json or a config file, instantly fixes this.
#closes#1126
* Formatting
* Remove hardcoded fix
The fix works, which means that the browserlist functionality works. It now pulls it automaticaly from the project (user project) config, or defaults to "defaults".
* Bump packages and add devPeers
It's common to add peerDependencies as devDependencies. This way, they _will_ be installed on development and thus you can test as if they're really there.
Some of the peerDependencies were missing in the first place.
Additionally, during development, we want to use the local react-static folder module, which is symlinked.
* Remove mapped names, update mocks and fix tests
Now that the configuration returns absolute paths, this updates the tests to also "mock" absolute paths.
* Update template versions
* Update urls to use react-static
Nozzle is no longer owning this repository.
* Update CHANGELOG and add RELEASE
* v7.2.0
* Collapse sites list

- Remove file inline-ing when the file is larger than an arbitrary size ([#1222](https://github.com/react-static/react-static/pull/1222))

- Fix relative paths when the should have been absolute ([#1250](https://github.com/react-static/react-static/pull/1250), [#1253](https://github.com/react-static/react-static/pull/1253), [#1254](https://github.com/react-static/react-static/pull/1254), [#1272](https://github.com/react-static/react-static/pull/1272) and [#1276](https://github.com/react-static/react-static/pull/1254))

- Common props returned by `getRouteProps` (props that `===` one another) now promoted to **shared props** and only requested once per session. Learn more in the docs: [Automatic Data and Prop Splitting](https://github.com/nozzle/react-static#automatic-data-and-prop-splitting). Depending on your site, this may significantly decrease site bandwidth and increase both initial page load speed and subsequent page load performance.

- Common props returned by `getRouteProps` (props that `===` one another) now promoted to **shared props** and only requested once per session. Learn more in the docs: [Automatic Data and Prop Splitting](https://github.com/react-static/react-static#automatic-data-and-prop-splitting). Depending on your site, this may significantly decrease site bandwidth and increase both initial page load speed and subsequent page load performance.

Version 8 will be focused on becoming compatible with async React which includes both suspense and the expected async server-side-renderer that has yet to be released. The goals for this version may include:

@@ -38,7 +38,7 @@ The routes that will be rendered are the **routes** returned by the `getRoutes`

###Custom `Routes` Rendering

Occasionally, you may need to render the automatic `<Routes>` component in a custom way. The most common use-case is illustrated in the [animated-routes](https://github.com/nozzle/react-static/tree/master/examples/animated-routes) example transitions. To do this, utilize a render prop:

Occasionally, you may need to render the automatic `<Routes>` component in a custom way. The most common use-case is illustrated in the [animated-routes](https://github.com/react-static/react-static/tree/master/examples/animated-routes) example transitions. To do this, utilize a render prop:

@@ -21,7 +21,7 @@ React Static also has a very unique and amazing way of requesting the least amou

-**Route Templates** - Under the hood, React Static automatically code splits your route templates for you. Other than assigning templates to routes in your `static.config.js`, you don't have to do anything else! Magic!

-**Route Data** - Each route's `getData` function results in a separate data file for each route being stored as JSON next to the routes HTML on export. This covers the 90% use case for data splitting, but if you want even more control and want to optimize repeated data across routes, you can use the `sharedData` and `createSharedData` api explained below.

-**Site Data** - For data that is needed in every (or most) routes, you can pass it in the `config.getSiteData` function and make it accessible to any page in your entire site!.

-**Manual Code Splitting with Universal** - React Static comes built in with support for [`react-universal-component`](https://github.com/faceyspacey/react-universal-component). This means aside from the automatic code splitting that React Static offers, you can also manually code split very large components if you choose to do so. See the ["About" page in the dynamic-imports example](https://github.com/nozzle/react-static/blob/master/examples/dynamic-imports/src/containers/About.js) to see how it works and how easy it is!

-**Manual Code Splitting with Universal** - React Static comes built in with support for [`react-universal-component`](https://github.com/faceyspacey/react-universal-component). This means aside from the automatic code splitting that React Static offers, you can also manually code split very large components if you choose to do so. See the ["About" page in the dynamic-imports example](https://github.com/react-static/react-static/blob/master/examples/dynamic-imports/src/containers/About.js) to see how it works and how easy it is!

Every React Static project can utilize the plugin API locally without needing to create a plugin by creating either `node.api.js` or `browser.api.js` files in the root of your project. See the [Plugin Documentation](https://github.com/nozzle/react-static/tree/master/docs/plugins) for more information!

Every React Static project can utilize the plugin API locally without needing to create a plugin by creating either `node.api.js` or `browser.api.js` files in the root of your project. See the [Plugin Documentation](https://github.com/react-static/react-static/tree/master/docs/plugins) for more information!

- [react-static-plugin-favicons](https://www.npmjs.com/package/react-static-plugin-favicons) - Generate (fav)icons in many different sizes for many different platforms, and add them to your site's metadata

- Other

@@ -140,4 +141,4 @@ Only the `plugins` directory will be transformed by react-static's babel runtime

The source for all default loaders can be found in [webpack/rules/ directory](https://github.com/nozzle/react-static/tree/master/packages/react-static/src/static/webpack/rules).

The source for all default loaders can be found in [webpack/rules/ directory](https://github.com/react-static/react-static/tree/master/packages/react-static/src/static/webpack/rules).

**Note:** Usage of the `oneOf` rule is recommended. This ensures each file is only handled by the first loader it matches, and not any loader. This also makes it easier to reutilize the default loaders, without having to fuss with `excludes`. Here are some examples of how to replace and modify the default loaders: