Skip to content
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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "solid-logic",
"version": "4.0.0",
"version": "4.0.1",
"description": "Core business logic of SolidOS",
"type": "module",
"main": "dist/solid-logic.js",
Expand Down
27 changes: 17 additions & 10 deletions test/testBundles/test-umd.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,25 @@
<body>
<h1>Solid Logic UMD Bundle Browser Test</h1>
Copy link

Copilot AI Dec 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The heading still says "Solid Logic UMD Bundle Browser Test", but the test has been converted to use ES modules (ESM) with import maps instead of a UMD bundle. The heading should be updated to "Solid Logic ESM Module Browser Test" or similar to accurately reflect what is being tested.

Copilot uses AI. Check for mistakes.
<pre id="output"></pre>
<!--- !!!--- first build dist with npm run build-dist ---!!! -->
<!-- Load solid-logic UMD bundle (adjust path if needed) -->
<script src="../../dist/solid-logic.js"></script>
<script>
// Test if SolidLogic is available
<script type="importmap">
{
"imports": {
"rdflib": "https://esm.sh/rdflib",
"solid-logic": "https://esm.sh/solid-logic"
Comment on lines +13 to +14
Copy link

Copilot AI Dec 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The import map points to https://esm.sh/solid-logic which will load the published version from npm. This means the test won't be testing the local development version of the code. If the intent is to test local changes before publishing, consider either: 1) pointing to a local build, 2) creating a separate test file for CDN validation, or 3) adding a comment explaining this tests the published version.

Copilot uses AI. Check for mistakes.
}
}
</script>
<script type="module">
import * as $rdf from "rdflib";
import { solidLogicSingleton, store, authn } from "solid-logic";
const output = document.getElementById('output');
if (window.SolidLogic) {
output.textContent = 'SolidLogic loaded!';
// Example: test a function if available
// output.textContent += '\n' + window.SolidLogic.someFunction();
if ($rdf && solidLogicSingleton && store && authn) {
output.textContent = 'SolidLogic and rdflib loaded as ESM!';
// Example usage
output.textContent += '\nStore: ' + (store ? 'available' : 'missing');
output.textContent += '\nAuthentication: ' + (authn.currentUser ? authn.currentUser() : 'missing');
} else {
output.textContent = 'SolidLogic NOT loaded!';
output.textContent = 'SolidLogic or rdflib NOT loaded!';
}
</script>
</body>
Expand Down