Add internationalization support with astro-i18next integration
- Implemented astro-i18next for multi-language support, including English, Dutch, and Italian. - Configured default locale and language fallback settings. - Defined routes for localized content in the configuration. - Updated package.json and package-lock.json to include new dependencies for i18next and related plugins.
This commit is contained in:
32
node_modules/locale-emoji/test.js
generated
vendored
Normal file
32
node_modules/locale-emoji/test.js
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
var localeEmoji = require('.');
|
||||
|
||||
describe('localeEmoji', function() {
|
||||
var tests = {
|
||||
'de': '🇩🇪',
|
||||
'de-DE': '🇩🇪',
|
||||
'de_DE': '🇩🇪',
|
||||
'de-CH': '🇨🇭',
|
||||
'en': '🇺🇸',
|
||||
'EN': '🇺🇸',
|
||||
'en-GB': '🇬🇧',
|
||||
'en-US': '🇺🇸',
|
||||
'EN-US': '🇺🇸',
|
||||
'EN-us': '🇺🇸',
|
||||
'en-us': '🇺🇸',
|
||||
'pt': '🇧🇷',
|
||||
'sk_Latin_SK': '🇸🇰',
|
||||
'eo': '',
|
||||
};
|
||||
|
||||
Object.keys(tests).forEach(function(from) {
|
||||
var to = tests[from];
|
||||
|
||||
it(from + ' -> ' + to, function() {
|
||||
expect(localeEmoji(from)).toEqual(to);
|
||||
});
|
||||
});
|
||||
|
||||
it('should return a empty string for invalid input', function() {
|
||||
expect(localeEmoji('potato')).toEqual('');
|
||||
});
|
||||
});
|
Reference in New Issue
Block a user