Skip to content

Commit

Permalink
docs(html-test-app/aggrid): replace cdn with bundled dependency (#1667)
Browse files Browse the repository at this point in the history
Co-authored-by: Julian Lamplmair <151610373+jul-lam@users.noreply.github.com>
  • Loading branch information
danielleroux and jul-lam authored Jan 29, 2025
1 parent d28d621 commit 7e4a748
Show file tree
Hide file tree
Showing 3 changed files with 313 additions and 73 deletions.
2 changes: 1 addition & 1 deletion packages/html-test-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@
"vite": "^3.1.0"
},
"dependencies": {
"ag-grid-community": "^32.1.0"
"ag-grid-community": "^33.0.4"
}
}
19 changes: 14 additions & 5 deletions packages/html-test-app/src/preview-examples/aggrid.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>AG Grid example</title>
<!-- External resources -->
<script src="https://cdn.jsdelivr.net/npm/ag-grid-community@32.1/dist/ag-grid-community.min.js"></script>

<!-- External resources -->
</head>
<body>
<div
Expand All @@ -25,7 +21,20 @@
class="ag-theme-alpine-dark ag-theme-ix"
></div>

<script>
<script type="module">
import {
AllCommunityModule,
ModuleRegistry,
provideGlobalGridOptions,
} from 'ag-grid-community';
import * as agGrid from 'ag-grid-community';

// Register all community features
ModuleRegistry.registerModules([AllCommunityModule]);

// Mark all grids as using legacy themes
provideGlobalGridOptions({ theme: 'legacy' });

(async function () {
const container = document.querySelector('#grid-container');

Expand Down
Loading

0 comments on commit 7e4a748

Please sign in to comment.