You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit d9e1d48
Browse filesBrowse the repository at this point in the historyBrowse files
[update] rework export path docs to public vs own server framing
- replace local-path/CDN bullet structure with public-vs-own-server approach
- update code examples to use x.x/worker.js?vx instead of next
- fix admonition syntax from {{note}} to :::note in loading_data.md
- remove inline comments from React props code example
exportModulePath:"../libs/json2excel/next/worker.js", //latest version; use x.x instead of next for a specific version
23
+
exportModulePath:"../libs/json2excel/x.x/worker.js?vx", //a local path to the `worker.js` file of the export module
24
24
// other config parameters
25
25
});
26
26
~~~
@@ -31,18 +31,12 @@ const spreadsheet = new dhx.Spreadsheet("spreadsheet", {
31
31
DHTMLX Spreadsheet uses the WebAssembly-based library [JSON2Excel](https://github.com/dhtmlx/json2excel) for export of data into Excel.
32
32
:::
33
33
34
-
To export files you need to:
34
+
To export files you need to set the path to the **worker.js** file of the [Json2Excel](https://github.com/dhtmlx/json2excel) library (where export will be processed) via the **exportModulePath** option. By default, `https://cdn.dhtmlx.com/libs/json2excel/next/worker.js?vx` is used.
35
+
- if you use the public export server, you don't need to specify the link to it, since it is used by default
36
+
- if you use your own export server, you need to:
37
+
- install the [**Json2Excel**](https://github.com/dhtmlx/json2excel) library
38
+
- use `"../libs/json2excel/x.x/worker.js?vx"` for a specific version (replace `x.x` with the version deployed on your server)
35
39
36
-
- install the **JSON2excel** library
37
-
- set the path to the **worker.js** file via the **exportModulePath** option in one of the two ways:
38
-
- by providing a local path to the file on your computer:
39
-
- use `"../libs/json2excel/next/worker.js"` for the latest version
40
-
- use `"../libs/json2excel/x.x/worker.js"` for a specific version (replace `x.x` with the actual version from the [GitHub repository](https://github.com/dhtmlx/json2excel))
41
-
- by providing a link to the file from CDN:
42
-
- use `"https://cdn.dhtmlx.com/libs/json2excel/next/worker.js?vx"` for the latest version
43
-
- use `"https://cdn.dhtmlx.com/libs/json2excel/x.x/worker.js?vx"` for a specific version (replace `x.x` with the actual version from the [GitHub repository](https://github.com/dhtmlx/json2excel))
44
-
45
-
By default, `https://cdn.dhtmlx.com/libs/json2excel/next/worker.js?vx` is used.
46
40
47
41
**Related articles:**[Data loading and export](loading_data.md#exporting-data)
Copy file name to clipboardExpand all lines: docs/loading_data.md
+13-12Lines changed: 13 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -300,22 +300,21 @@ DHTMLX Spreadsheet provides the ability to export data from a spreadsheet into a
300
300
301
301
#### How to export data
302
302
303
-
{{note Please note that the export feature won't work in the Internet Explorer browser.}}
303
+
:::note
304
+
Please note that the export feature won't work in the Internet Explorer browser.
305
+
:::
304
306
305
-
The library uses the WebAssembly-based library [Json2Excel](https://github.com/dhtmlx/json2excel) to enable the functionality of export to Excel. Thus, to have the possibility of exporting files you need to:
307
+
The library uses the WebAssembly-based library [Json2Excel](https://github.com/dhtmlx/json2excel) to enable the functionality of export to Excel. Export is processed at the **worker.js** file of the **Json2Excel** library (the default link is `https://cdn.dhtmlx.com/libs/json2excel/next/worker.js?vx`). You can use either the public export server or a local export server. Thus, to have the possibility of exporting files you need to:
306
308
307
-
- install the **JSON2Excel** library
308
-
- specify the [](api/spreadsheet_exportmodulepath_config.md) option in the Spreadsheet configuration and set the path to the **worker.js** file in one of the two ways:
309
-
- by providing a local path to the file on your computer:
310
-
- use `"../libs/json2excel/next/worker.js"` for the latest version
311
-
- use `"../libs/json2excel/x.x/worker.js"` for a specific version (replace `x.x` with the actual version from the [GitHub repository](https://github.com/dhtmlx/json2excel))
312
-
- by providing a link to the file from CDN:
313
-
- use `"https://cdn.dhtmlx.com/libs/json2excel/next/worker.js?vx"` for the latest version
314
-
- use `"https://cdn.dhtmlx.com/libs/json2excel/x.x/worker.js?vx"` for a specific version (replace `x.x` with the actual version from the [GitHub repository](https://github.com/dhtmlx/json2excel))
309
+
- specify the [](api/spreadsheet_exportmodulepath_config.md) option in the Spreadsheet configuration and set the path to the **worker.js** file:
310
+
- if you use the public export server, you don't need to specify the link to it, since it is used by default
311
+
- if you use your own export server, you need to:
312
+
- install the [**Json2Excel**](https://github.com/dhtmlx/json2excel) library
313
+
- use `"../libs/json2excel/x.x/worker.js?vx"` for a specific version (replace `x.x` with the version deployed on your server)
315
314
316
315
~~~jsx
317
316
var spreadsheet =newdhx.Spreadsheet(document.body, {
318
-
exportModulePath:"../libs/json2excel/next/worker.js"//latest version; use x.x instead of next for a specific version
317
+
exportModulePath:"../libs/json2excel/x.x/worker.js?vx"//the path to the export module, if a local export server is used
0 commit comments