Skip to content

Commit c5ed054

Browse files
authored
Add import demos useful for testing handsontable/hyperformula#1377 (#27)
* Add demos for different ways of importing HyperFormula * Update parcel demo to 2.11 * Test also the new ways of importing HF * Add import demo for webpack 4 * Remove webpack4 import demo * Add import demo webpack 4 * Add import demo for webpack 5 with ESM * Add import demo for webpack 5 with CJS * Add import demo for Webpack 5 with typescript * Add import demo for Svelte * Add import demo angular ESM * Make angular 18 import demo work * Add import demo for angular 16 and typescript 4 * Add Angular 18 sample app * Add more angular demos * Add import-demo-esm-webpack-5-ts-5 demo with a webpack boilerplate code (without typescript yet) * Add webpack+TS demos * Add webpack 5 demo without babel * Add webpack 4 demo without babel * Fix import-demo-esm-webpack-4-babel * Remove babel from import-demo-esm-parcel
1 parent a137eb8 commit c5ed054

File tree

181 files changed

+179752
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

181 files changed

+179752
-0
lines changed

import-demo-cjs-node/index.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
const { HyperFormula, AlwaysDense } = require('hyperformula');
2+
3+
// new way
4+
const { enUS } = require('hyperformula/i18n/languages');
5+
const { default: frFR } = require('hyperformula/i18n/languages/frFR');
6+
7+
// legacy way
8+
const { csCZ } = require('hyperformula/commonjs/i18n/languages');
9+
const { default: daDK } = require('hyperformula/commonjs/i18n/languages/daDK');
10+
const { default: deDE } = require('hyperformula/commonjs/i18n/languages/deDE.js');
11+
12+
console.log(HyperFormula != null);
13+
console.log(AlwaysDense != null);
14+
console.log(enUS != null);
15+
console.log(frFR != null);
16+
console.log(csCZ != null);
17+
console.log(daDK != null);
18+
console.log(deDE != null);
19+
20+
HyperFormula.registerLanguage('enUS', enUS);
21+
HyperFormula.registerLanguage('frFR', frFR);
22+
HyperFormula.registerLanguage('csCZ', csCZ);
23+
HyperFormula.registerLanguage('daDK', daDK);
24+
HyperFormula.registerLanguage('deDE', deDE);
25+
26+
// npm i --registry http://localhost:4873 [email protected]

0 commit comments

Comments
 (0)