Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@formatjs/intl-locale

Package Overview
Dependencies
Maintainers
3
Versions
118
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@formatjs/intl-locale - npm Package Compare versions

Comparing version 2.4.32 to 2.4.33

12

index.js

@@ -7,5 +7,3 @@ "use strict";

var intl_getcanonicallocales_1 = require("@formatjs/intl-getcanonicallocales");
var likelySubtagsData = tslib_1.__importStar(require("cldr-core/supplemental/likelySubtags.json"));
var get_internal_slots_1 = tslib_1.__importDefault(require("./get_internal_slots"));
var likelySubtags = likelySubtagsData.supplemental.likelySubtags;
var RELEVANT_EXTENSION_KEYS = ['ca', 'co', 'hc', 'kf', 'kn', 'nu'];

@@ -114,3 +112,3 @@ var UNICODE_TYPE_REGEX = /^[a-z0-9]{3,8}(-[a-z0-9]{3,8})*$/i;

if (script && region) {
var match_1 = likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: lang, script: script, region: region, variants: [] })];
var match_1 = intl_getcanonicallocales_1.likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: lang, script: script, region: region, variants: [] })];
if (match_1) {

@@ -123,3 +121,3 @@ var parts_1 = intl_getcanonicallocales_1.parseUnicodeLanguageId(match_1);

if (script) {
var match_2 = likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: lang, script: script, variants: [] })];
var match_2 = intl_getcanonicallocales_1.likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: lang, script: script, variants: [] })];
if (match_2) {

@@ -132,3 +130,3 @@ var parts_2 = intl_getcanonicallocales_1.parseUnicodeLanguageId(match_2);

if (region) {
var match_3 = likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: lang, region: region, variants: [] })];
var match_3 = intl_getcanonicallocales_1.likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: lang, region: region, variants: [] })];
if (match_3) {

@@ -140,4 +138,4 @@ var parts_3 = intl_getcanonicallocales_1.parseUnicodeLanguageId(match_3);

}
var match = likelySubtags[lang] ||
likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: 'und', script: script, variants: [] })];
var match = intl_getcanonicallocales_1.likelySubtags[lang] ||
intl_getcanonicallocales_1.likelySubtags[intl_getcanonicallocales_1.emitUnicodeLanguageId({ lang: 'und', script: script, variants: [] })];
if (!match) {

@@ -144,0 +142,0 @@ throw new Error("No match for addLikelySubtags");

import { __assign, __spreadArray } from "tslib";
import { GetOption, invariant, SameValue, CoerceOptionsToObject, } from '@formatjs/ecma402-abstract';
import { isStructurallyValidLanguageTag, isUnicodeLanguageSubtag, isUnicodeRegionSubtag, parseUnicodeLanguageId, isUnicodeScriptSubtag, emitUnicodeLocaleId, parseUnicodeLocaleId, emitUnicodeLanguageId, } from '@formatjs/intl-getcanonicallocales';
import * as likelySubtagsData from 'cldr-core/supplemental/likelySubtags.json';
import { isStructurallyValidLanguageTag, isUnicodeLanguageSubtag, isUnicodeRegionSubtag, parseUnicodeLanguageId, isUnicodeScriptSubtag, emitUnicodeLocaleId, parseUnicodeLocaleId, emitUnicodeLanguageId, likelySubtags, } from '@formatjs/intl-getcanonicallocales';
import getInternalSlots from './get_internal_slots';
var likelySubtags = likelySubtagsData.supplemental.likelySubtags;
var RELEVANT_EXTENSION_KEYS = ['ca', 'co', 'hc', 'kf', 'kn', 'nu'];

@@ -8,0 +6,0 @@ var UNICODE_TYPE_REGEX = /^[a-z0-9]{3,8}(-[a-z0-9]{3,8})*$/i;

{
"name": "@formatjs/intl-locale",
"version": "2.4.32",
"version": "2.4.33",
"description": "Intl.Locale polyfill",

@@ -27,7 +27,6 @@ "keywords": [

"dependencies": {
"@formatjs/ecma402-abstract": "1.9.3",
"@formatjs/intl-getcanonicallocales": "1.7.0",
"cldr-core": "38",
"@formatjs/ecma402-abstract": "1.9.4",
"@formatjs/intl-getcanonicallocales": "1.7.1",
"tslib": "^2.1.0"
}
}

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 too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc