Skip to content

Remove Nutrient assets copy requirement from examples. #25

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
May 29, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion examples/angular/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"noPropertyAccessFromIndexSignature": true,
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true,
"skipLibCheck": true,
"isolatedModules": true,
"esModuleInterop": true,
"sourceMap": true,
Expand Down
13 changes: 1 addition & 12 deletions examples/electron/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 2 additions & 4 deletions examples/electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
"package-mac-intel": "electron-packager . --no-prune --overwrite --platform=darwin --arch=x64 --out=release-builds --icon=icons/mac/application.icns",
"package-mac-apple": "electron-packager . --no-prune --overwrite --platform=darwin --arch=arm64 --out=release-builds --icon=icons/mac/application.icns",
"package-win": "electron-packager . --no-prune --overwrite --platform=win32 --arch=x64 --out=release-builds --icon=icons/win/application.ico",
"package-linux": "electron-packager . --no-prune --overwrite --platform=linux --arch=x64 --out=release-builds --icon=icons/png/application.png",
"postinstall": "node scripts/copy-nutrient-files.js"
"package-linux": "electron-packager . --no-prune --overwrite --platform=linux --arch=x64 --out=release-builds --icon=icons/png/application.png"
},
"author": "Nutrient (https://www.nutrient.io)",
"homepage": "https://www.nutrient.io/web",
Expand All @@ -26,8 +25,7 @@
],
"devDependencies": {
"@electron/packager": "^18.3.6",
"electron": "^33.2.0",
"ncp": "^2.0.0"
"electron": "^33.2.0"
},
"dependencies": {
"@nutrient-sdk/viewer": "1.3.0"
Expand Down
16 changes: 0 additions & 16 deletions examples/electron/scripts/copy-nutrient-files.js

This file was deleted.

2 changes: 1 addition & 1 deletion examples/electron/src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
<header></header>
<div id="root"></div>

<script src="./nutrient-viewer.js"></script>
<script src="../node_modules/@nutrient-sdk/viewer/dist/nutrient-viewer.js"></script>

<script type="module">
import { dragAndDrop } from "./lib/drag-and-drop.js";
Expand Down
10 changes: 0 additions & 10 deletions examples/gatsbyjs/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions examples/gatsbyjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"start": "npm run develop",
"serve": "gatsby serve",
"test": "echo \"Write tests! -> https://gatsby.dev/unit-testing \"",
"postinstall": "node scripts/copy-nutrient-files",
"start:e2e": "npm run start"
},
"dependencies": {
Expand All @@ -25,7 +24,6 @@
"react-dom": "^18.0.0"
},
"devDependencies": {
"ncp": "^2.0.0",
"prettier": "^3.3.2"
},
"overrides": {
Expand Down
10 changes: 0 additions & 10 deletions examples/gatsbyjs/scripts/copy-nutrient-files.js

This file was deleted.

5 changes: 1 addition & 4 deletions examples/laravel/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,12 @@ cd nutrient-web-examples/examples/laravel
npm install
```

6. Run `npm run dev` to copy the Nutrient artifacts to your `public/assets/nutrient/` folder.

Make sure your `/public/assets/nutrient/` folder contains the file `nutrient-viewer.js` and a `nutrient-viewer-lib` directory with library assets.

## Running the Example

We are ready to launch the app! 🎉

```bash
npm run dev
php artisan serve
```

Expand Down
11 changes: 0 additions & 11 deletions examples/laravel/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 2 additions & 4 deletions examples/laravel/package.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
{
"private": true,
"scripts": {
"verify-installation": "node scripts/verify-install.js && node scripts/copy-nutrient-files.js",
"dev": "npm run verify-installation && npm run development",
"prod": "npm run verify-installation && npm run production",
"dev": "npm run development",
"prod": "npm run production",
"development": "mix",
"watch": "mix watch",
"watch-poll": "mix watch -- --watch-options-poll=1000",
Expand All @@ -14,7 +13,6 @@
"axios": "^1.7.7",
"laravel-mix": "^6.0.6",
"lodash": "^4.17.19",
"ncp": "^2.0.0",
"postcss": "^8.1.14"
},
"dependencies": {
Expand Down
23,429 changes: 23,427 additions & 2 deletions examples/laravel/public/js/app.js

Large diffs are not rendered by default.

Loading
Loading