![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.
bing-translate-api
Advanced tools
A simple and free API for Bing & Microsoft Translator for Node.js
A simple and free API for Bing Translator and Microsoft Translator for Node.js.
npm install bing-translate-api
Added since v4.0.0. More stable and powerful. Both free service and paid service are supported. Feel free to give it a try!
Read the README for more details.
From auto-detected language to English:
const { translate } = require('bing-translate-api');
translate('你好', null, 'en').then(res => {
console.log(res.translation);
}).catch(err => {
console.error(err);
});
Translation result
{
// original text
"text": "你好",
// user-specified language code
"userLang": "auto-detect",
// translated text
"translation": "Hello",
// `correctedText` is returned only when `correct` is set as `true`
// supported since v1.1.0
"correctedText": "",
// detected language
"language": {
// language code of translated text
"to": "en",
// detected language code of original text
"from": "zh-Hans",
// score of language detection
// supported since v1.1.0
"score": 1
}
}
Type: string
The text to be translated, can't be blank. The maximum text length is 1000.
NOTE:
v3.0.0
), the maximum text length is currently 3000.Type: string
Default: auto-detect
The language code of source text.
MUST be auto-detect
or one of the codes/names (not case sensitive) contained in lang.json
NOTE: The EPT mode (since v3.0.0
) only supports the languages contained in src/config.json#eptLangs. Any other language will fall back to the legacy mode, in which a 429 (Too Many Requests) error often occurs.
Type: string
Default: en
The language in which the text should be translated.
MUST be one of the codes/names (not case sensitive) contained in lang.json.
NOTE: The EPT mode (since v3.0.0
) only supports the languages contained in src/config.json#eptLangs. Any other language will fall back to the legacy mode, in which a 429 (Too Many Requests) error often occurs.
Type: boolean
Default: false
Since: v1.1.0
Whether to correct the input text.
Note that:
Type: boolean
Default: false
Whether the translation result contains raw response from Bing API.
Type: string
The header value of user-agent
used in API requests.
Refer to src/config.json#userAgent for the default user agent.
Type: Got['Agents']
Default: undefined
Since: v2.4.0
MIT © 2021-2024 plainheart.
Great thanks to Bing Translator for providing such an excellent translation service.
FAQs
A simple and free API for Bing & Microsoft Translator for Node.js
The npm package bing-translate-api receives a total of 0 weekly downloads. As such, bing-translate-api popularity was classified as not popular.
We found that bing-translate-api demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer 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.