@wordpress/i18n
Advanced tools
Comparing version 3.11.0 to 3.12.0
@@ -21,3 +21,3 @@ /** | ||
* @param {string} format The format of the string to generate. | ||
* @param {...string} args Arguments to apply to the format. | ||
* @param {...*} args Arguments to apply to the format. | ||
* | ||
@@ -24,0 +24,0 @@ * @see http://www.diveintojavascript.com/projects/javascript-sprintf |
@@ -6,3 +6,3 @@ /** | ||
* @param {string} format The format of the string to generate. | ||
* @param {...string} args Arguments to apply to the format. | ||
* @param {...*} args Arguments to apply to the format. | ||
* | ||
@@ -13,3 +13,3 @@ * @see http://www.diveintojavascript.com/projects/javascript-sprintf | ||
*/ | ||
export function sprintf(format: string, ...args: string[]): string; | ||
export function sprintf(format: string, ...args: any[]): string; | ||
//# sourceMappingURL=sprintf.d.ts.map |
@@ -32,3 +32,3 @@ "use strict"; | ||
* @param {string} format The format of the string to generate. | ||
* @param {...string} args Arguments to apply to the format. | ||
* @param {...*} args Arguments to apply to the format. | ||
* | ||
@@ -35,0 +35,0 @@ * @see http://www.diveintojavascript.com/projects/javascript-sprintf |
## Master | ||
## 3.12.0 (2020-04-30) | ||
### Bug Fix | ||
- Relax type of `sprintf` arguments type ([#21919](https://github.com/WordPress/gutenberg/pull/21919)) | ||
## 3.11.0 (2020-04-15) | ||
### New Feature | ||
### New Features | ||
- Add `isRTL` function ([#20298](https://github.com/WordPress/gutenberg/pull/20298)) | ||
- Include TypeScript type declarations ([#18942](https://github.com/WordPress/gutenberg/pull/18942)) | ||
- Add `createI18n` method to allow creation of multiple i18n instances ([#21182](https://github.com/WordPress/gutenberg/pull/21182)) | ||
## 3.10.0 (2020-04-01) | ||
### New Feature | ||
- Add `isRTL` function ([#20298](https://github.com/WordPress/gutenberg/pull/20298)) | ||
## 3.1.0 (2018-11-15) | ||
@@ -12,0 +23,0 @@ |
{ | ||
"name": "@wordpress/i18n", | ||
"version": "3.11.0", | ||
"version": "3.12.0", | ||
"description": "WordPress internationalization (i18n) library.", | ||
@@ -38,3 +38,3 @@ "author": "The WordPress Contributors", | ||
}, | ||
"gitHead": "65dbf3a9503402ca3837090dc89d0207f7d96352" | ||
"gitHead": "0bd9521bc2b7e78a65ccc3e21cfc068aec086786" | ||
} |
@@ -82,3 +82,3 @@ # Internationalization (i18n) | ||
- _format_ `string`: The format of the string to generate. | ||
- _args_ `...string`: Arguments to apply to the format. | ||
- _args_ `...*`: Arguments to apply to the format. | ||
@@ -85,0 +85,0 @@ _Returns_ |
@@ -21,3 +21,3 @@ /** | ||
* @param {string} format The format of the string to generate. | ||
* @param {...string} args Arguments to apply to the format. | ||
* @param {...*} args Arguments to apply to the format. | ||
* | ||
@@ -24,0 +24,0 @@ * @see http://www.diveintojavascript.com/projects/javascript-sprintf |
@@ -26,3 +26,9 @@ // Mock memoization as identity function. Inline since Jest errors on | ||
} ); | ||
it( 'replaces named placeholders', () => { | ||
const result = sprintf( 'bonjour %(name)s', { name: 'Riad' } ); | ||
expect( result ).toBe( 'bonjour Riad' ); | ||
} ); | ||
} ); | ||
} ); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
1456
0
292312