swipl-wasm 3.3.1 → 3.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -100,7 +100,7 @@ the `.js` file instead.
|
|
|
100
100
|
|
|
101
101
|
## Generating an image
|
|
102
102
|
|
|
103
|
-
Often you will want to bundle a pre-built image of your
|
|
103
|
+
Often you will want to bundle a pre-built image of your Prolog file. The easiest way to do this is using the `swipl-generate` command to generate the image. For example in `./examples/generation` the script: `swipl-generate ./max.pl ./dist/max.ts` will generate a file `./dist/max.ts` which contains the image of `./max.pl`. This file can then be imported into your project and used as follows:
|
|
104
104
|
|
|
105
105
|
```ts
|
|
106
106
|
import SWIPL from './max';
|
|
@@ -209,6 +209,21 @@ The package can be built using npm. Please use npm to
|
|
|
209
209
|
add new dependencies and update package-lock.json file. SWI-Prolog WebAssembly
|
|
210
210
|
version is currently built inside Docker with Emscripten.
|
|
211
211
|
|
|
212
|
+
### Development
|
|
213
|
+
|
|
214
|
+
To develop with this package, clone the repository and run:
|
|
215
|
+
|
|
216
|
+
```
|
|
217
|
+
# Install dependencies
|
|
218
|
+
npm ci
|
|
219
|
+
# Build the WebAssembly
|
|
220
|
+
npm run build
|
|
221
|
+
# Run tests
|
|
222
|
+
npm t
|
|
223
|
+
```
|
|
224
|
+
|
|
225
|
+
*Note* You need Docker and Node 16 or higher to installed build the package.
|
|
226
|
+
|
|
212
227
|
## Versioning
|
|
213
228
|
|
|
214
229
|
The package uses its own versioning scheme using semver. It is
|