@wordpress/element
Advanced tools
Comparing version 2.11.0 to 2.12.0
@@ -1,2 +0,2 @@ | ||
export { default as __experimentalCreateInterpolateElement } from './create-interpolate-element'; | ||
export { default as createInterpolateElement } from './create-interpolate-element'; | ||
export * from './react'; | ||
@@ -3,0 +3,0 @@ export * from './react-platform'; |
@@ -9,3 +9,3 @@ "use strict"; | ||
var _exportNames = { | ||
__experimentalCreateInterpolateElement: true, | ||
createInterpolateElement: true, | ||
Platform: true, | ||
@@ -15,3 +15,3 @@ renderToString: true, | ||
}; | ||
Object.defineProperty(exports, "__experimentalCreateInterpolateElement", { | ||
Object.defineProperty(exports, "createInterpolateElement", { | ||
enumerable: true, | ||
@@ -18,0 +18,0 @@ get: function get() { |
@@ -0,1 +1,5 @@ | ||
## Master | ||
- Graduated `__experimentalCreateInterpolateElement` function to stable api: `createInterpolateElement` (see [20699](https://github.com/WordPress/gutenberg/pull/20699)) | ||
## 2.10.0 (2019-12-19) | ||
@@ -5,3 +9,3 @@ | ||
- Added `__experimentalCreateInterpolateElement` function (see [17376](https://github.com/WordPress/gutenberg/pull/17376)) | ||
- Added `__experimentalCreateInterpolateElement` function (see [17376](https://github.com/WordPress/gutenberg/pull/17376)) | ||
@@ -12,4 +16,4 @@ ## 2.8.0 (2019-09-16) | ||
- The bundled `react` dependency has been updated from requiring `^16.8.4` to requiring `^16.9.0` ([#16982](https://github.com/WordPress/gutenberg/pull/16982)). It contains [new deprecations](https://reactjs.org/blog/2019/08/08/react-v16.9.0.html#new-deprecations) as well. | ||
- The bundled `react-dom` dependency has been updated from requiring `^16.8.4` to requiring `^16.9.0` ([#16982](https://github.com/WordPress/gutenberg/pull/16982)). | ||
- The bundled `react` dependency has been updated from requiring `^16.8.4` to requiring `^16.9.0` ([#16982](https://github.com/WordPress/gutenberg/pull/16982)). It contains [new deprecations](https://reactjs.org/blog/2019/08/08/react-v16.9.0.html#new-deprecations) as well. | ||
- The bundled `react-dom` dependency has been updated from requiring `^16.8.4` to requiring `^16.9.0` ([#16982](https://github.com/WordPress/gutenberg/pull/16982)). | ||
@@ -20,4 +24,4 @@ ## 2.4.0 (2019-05-21) | ||
- Added `lazy` feautre (see: https://reactjs.org/docs/react-api.html#reactlazy). | ||
- Added `Suspense` component (see: https://reactjs.org/docs/react-api.html#reactsuspense). | ||
- Added `lazy` feautre (see: https://reactjs.org/docs/react-api.html#reactlazy). | ||
- Added `Suspense` component (see: https://reactjs.org/docs/react-api.html#reactsuspense). | ||
@@ -28,12 +32,12 @@ ## 2.3.0 (2019-03-06) | ||
- Added `useCallback` hook (see: https://reactjs.org/docs/hooks-reference.html#usecallback). | ||
- Added `useContext` hook (see: https://reactjs.org/docs/hooks-reference.html#usecontext). | ||
- Added `useDebugValue` hook (see: https://reactjs.org/docs/hooks-reference.html#usedebugvalue). | ||
- Added `useEffect` hook (see: https://reactjs.org/docs/hooks-reference.html#useeffect). | ||
- Added `useImperativeHandle` hook (see: https://reactjs.org/docs/hooks-reference.html#useimperativehandle). | ||
- Added `useLayoutEffect` hook (see: https://reactjs.org/docs/hooks-reference.html#uselayouteffect). | ||
- Added `useMemo` hook (see: https://reactjs.org/docs/hooks-reference.html#usememo). | ||
- Added `useReducer` hook (see: https://reactjs.org/docs/hooks-reference.html#usereducer). | ||
- Added `useRef` hook (see: https://reactjs.org/docs/hooks-reference.html#useref). | ||
- Added `useState` hook (see: https://reactjs.org/docs/hooks-reference.html#usestate). | ||
- Added `useCallback` hook (see: https://reactjs.org/docs/hooks-reference.html#usecallback). | ||
- Added `useContext` hook (see: https://reactjs.org/docs/hooks-reference.html#usecontext). | ||
- Added `useDebugValue` hook (see: https://reactjs.org/docs/hooks-reference.html#usedebugvalue). | ||
- Added `useEffect` hook (see: https://reactjs.org/docs/hooks-reference.html#useeffect). | ||
- Added `useImperativeHandle` hook (see: https://reactjs.org/docs/hooks-reference.html#useimperativehandle). | ||
- Added `useLayoutEffect` hook (see: https://reactjs.org/docs/hooks-reference.html#uselayouteffect). | ||
- Added `useMemo` hook (see: https://reactjs.org/docs/hooks-reference.html#usememo). | ||
- Added `useReducer` hook (see: https://reactjs.org/docs/hooks-reference.html#usereducer). | ||
- Added `useRef` hook (see: https://reactjs.org/docs/hooks-reference.html#useref). | ||
- Added `useState` hook (see: https://reactjs.org/docs/hooks-reference.html#usestate). | ||
@@ -54,3 +58,3 @@ ## 2.1.8 (2018-11-15) | ||
- New API method `isEmptyElement` was introduced ([9861](https://github.com/WordPress/gutenberg/pull/9681/)). | ||
- New API method `isEmptyElement` was introduced ([9861](https://github.com/WordPress/gutenberg/pull/9681/)). | ||
@@ -61,2 +65,2 @@ ## 2.0.0 (2018-09-05) | ||
- Change how required built-ins are polyfilled with Babel 7 ([#9171](https://github.com/WordPress/gutenberg/pull/9171)). If you're using an environment that has limited or no support for ES2015+ such as lower versions of IE then using [core-js](https://github.com/zloirock/core-js) or [@babel/polyfill](https://babeljs.io/docs/en/next/babel-polyfill) will add support for these methods. | ||
- Change how required built-ins are polyfilled with Babel 7 ([#9171](https://github.com/WordPress/gutenberg/pull/9171)). If you're using an environment that has limited or no support for ES2015+ such as lower versions of IE then using [core-js](https://github.com/zloirock/core-js) or [@babel/polyfill](https://babeljs.io/docs/en/next/babel-polyfill) will add support for these methods. |
{ | ||
"name": "@wordpress/element", | ||
"version": "2.11.0", | ||
"version": "2.12.0", | ||
"description": "Element React module for WordPress.", | ||
@@ -35,3 +35,3 @@ "author": "The WordPress Contributors", | ||
}, | ||
"gitHead": "41fc84af285da696c65c235331ee245dfe23971d" | ||
"gitHead": "6e2ca778fb69c67188479b491cf2e802011d72e2" | ||
} |
@@ -141,2 +141,34 @@ # Element | ||
<a name="createInterpolateElement" href="#createInterpolateElement">#</a> **createInterpolateElement** | ||
This function creates an interpolated element from a passed in string with | ||
specific tags matching how the string should be converted to an element via | ||
the conversion map value. | ||
_Usage_ | ||
For example, for the given string: | ||
"This is a <span>string</span> with <a>a link</a> and a self-closing | ||
<CustomComponentB/> tag" | ||
You would have something like this as the conversionMap value: | ||
```js | ||
{ | ||
span: <span />, | ||
a: <a href={ 'https://github.com' } />, | ||
CustomComponentB: <CustomComponent />, | ||
} | ||
``` | ||
_Parameters_ | ||
- _interpolatedString_ `string`: The interpolation string to be parsed. | ||
- _conversionMap_ `Object`: The map used to convert the string to a react element. | ||
_Returns_ | ||
- `WPElement`: A wp element. | ||
<a name="createPortal" href="#createPortal">#</a> **createPortal** | ||
@@ -143,0 +175,0 @@ |
@@ -1,2 +0,2 @@ | ||
export { default as __experimentalCreateInterpolateElement } from './create-interpolate-element'; | ||
export { default as createInterpolateElement } from './create-interpolate-element'; | ||
export * from './react'; | ||
@@ -3,0 +3,0 @@ export * from './react-platform'; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
295362
418