![Create React App Officially Deprecated Amid React 19 Compatibility Issues](https://cdn.sanity.io/images/cgdhsj6q/production/04fa08cf844d798abc0e1a6391c129363cc7e2ab-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
@bbc/psammead-detokeniser
Advanced tools
Replaces % delimited tokens with a value from the dictionary object
The detokeniser
utility operates on strings and replaces % delimited tokens with a value from the dictionary object.
npm install @bbc/psammead-detokeniser --save
Argument | Type | Required | Default | Example |
---|---|---|---|---|
text | string | yes | N/A | 'Foo %token%' |
dictionary | object | yes | N/A | { '%token%': 'Bar' } |
dictionary
is an object which maps keys as tokens to values. For example, in psammead-social-embeds
, all social media providers in the data are in lowercase which corresponds as the token to be interpolated into the full name.
E.g. '%youtube%' -> 'YouTube'
import detokenise from "@bbc/psammead-detokeniser"
// This will return 'Duration: 20 minutes'
detokenise('Duration: %token%', { '%token%': '20 minutes' });
Psammead is completely open source. We are grateful for any contributions, whether they be new utilities, bug fixes or general improvements. Please see our primary contributing guide which can be found at the root of the Psammead repository.
We welcome feedback and help on this work. By participating in this project, you agree to abide by the code of conduct. Please take a moment to read it.
Psammead is Apache 2.0 licensed.
FAQs
Replaces % delimited tokens with a value from the dictionary object
The npm package @bbc/psammead-detokeniser receives a total of 9 weekly downloads. As such, @bbc/psammead-detokeniser popularity was classified as not popular.
We found that @bbc/psammead-detokeniser demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 40 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.