@zengenti/contensis-react-base 3.3.0 → 3.3.1-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +12 -0
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -6,6 +6,18 @@ Handles web app routing with Contensis Site View and component rendering based o
6
6
 
7
7
  ## Upgrade notes (older projects)
8
8
 
9
+ ### Styled Components 6 (v3.3+)
10
+
11
+ Some projects may see console warnings in the web app like the example below after upgrading to v3.3+ which updates Styled Components from version 5 to 6
12
+
13
+ ```
14
+ styled-components: it looks like an unknown prop "maxWidth" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)
15
+
16
+ React does not recognize the `maxWidth` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `maxwidth` instead. If you accidentally passed it from a parent component, remove it from the DOM element.
17
+ ```
18
+
19
+ To fix these warnings we can opt-in to certain behaviours from Styled Components v5 by wrapping the top-level components in `App` in a `StyleSheetManager` component and handlers for suppressing the necessary warnings. [Further reading](https://styled-components.com/docs/faqs#shouldforwardprop-is-no-longer-provided-by-default)
20
+
9
21
  ### React 17 (v3.0+)
10
22
 
11
23
  This version introduces React v17. React is very sensitive to having multiple versions installed at the same time.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zengenti/contensis-react-base",
3
- "version": "3.3.0",
3
+ "version": "3.3.1-beta.0",
4
4
  "repository": "https://github.com/zengenti/contensis-react-base",
5
5
  "license": "None",
6
6
  "description": "Turbocharge your React web apps with Contensis. This package handles all dependencies for creating full featured web apps in React with Contensis and Site View. Routing is driven by Site View, Redux is used for global state management and server-side rendering (SSR) is handled for you. Also taking care of intricate hosting issues such as cache invalidation and supporting authenticated content where required.",