
Security News
Crates.io Users Targeted by Phishing Emails
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
react-localize
Advanced tools
A simple context wrapper and text localization component for localizing strings
A simple React Context wrapper and text localization component for localizing strings.
Please refer to our gitbook documentation for more detailed information & resources.
npm i react-localize
*or via yarn add react-localize
import { LocalizationProvider, LocalizationConsumer } from 'react-localize';
// this should come from your server or localization strings bundle source
// for your application.
const localizationBundle = {
'app.button.Submit': 'Submit',
foo: {
bar: 'Hey %s, you must be %d years old?'
}
};
<LocalizationProvider messages={localizationBundle}>
<AnyParentComponent>
<LocalizationConsumer>
{({ localize }) => {
return <div>
<h1>{localize('prop.MissingValue')}</h1>
<button>{localize('app.button.Submit')}</button>
<p>{localize('foo.bar', ['Stephen', 34])}</p>
</div>;
}}
</LocalizationConsumer>
</AnyParentComponent>
</LocalizationProvider>
// outputs:
// <div>
// <h1>prop.MissingValue</h1>
// <button>Submit</button>
// <p>Hey Stephen, you must be 34 years old?</p>
// </div>
FAQs
A simple context wrapper and text localization component for localizing strings
We found that react-localize demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 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
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
Product
Socket now lets you customize pull request alert headers, helping security teams share clear guidance right in PRs to speed reviews and reduce back-and-forth.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.