Skip to content
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

Migrate xmldom to @xmldom/xmldom #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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 README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ yarn run xsd-ts example/greeting.xsd example/greeting.ts
```ts
// feed xml dom into parser to get the typed valid object structure
import { readFileSync } from 'fs';
import { DOMParser } from 'xmldom';
import { DOMParser } from '@xmldom/xmldom';
import parse from './greeting.ts';

const xml = readFileSync('example/greeting.xml', 'utf8');
Expand Down
8 changes: 4 additions & 4 deletions example/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@xsd-tools/example",
"version": "0.1.1",
"version": "0.1.2",
"private": true,
"description": "Examples for xsd-tools",
"author": "David Knezić <davidknezic@gmail.com>",
Expand All @@ -18,12 +18,12 @@
"url": "https://github.com/pocketbitcoin/xsd-tools/issues"
},
"dependencies": {
"xmldom": "^0.6.0",
"xsd-tools": "^0.1.1"
"@xmldom/xmldom": "^0.8.7",
"xsd-tools": "^0.2.1"
},
"devDependencies": {
"@types/xmldom": "^0.1.31",
"@xsd-tools/typescript": "^0.1.1",
"@xsd-tools/typescript": "^0.2.1",
"ts-node": "^10.9.1",
"typescript": "^4.9.5"
}
Expand Down
2 changes: 1 addition & 1 deletion example/src/example.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { readFileSync } from 'fs';
import { resolve } from 'path';
import { DOMParser } from 'xmldom';
import { DOMParser } from '@xmldom/xmldom';
import parse from './greeting';

const xml = readFileSync(resolve(__dirname, '../greeting.xml'), 'utf8');
Expand Down
10 changes: 5 additions & 5 deletions packages/typescript/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@xsd-tools/typescript",
"version": "0.2.0",
"version": "0.2.1",
"description": "Schema-driven XML parser generator for TypeScript",
"keywords": [
"xsd",
Expand Down Expand Up @@ -40,20 +40,20 @@
},
"peerDependencies": {
"typescript": "^4.0.0",
"xsd-tools": "^0.1.0"
"xsd-tools": "^0.2.1"
},
"dependencies": {
"@xmldom/xmldom": "^0.8.7",
"commander": "^10.0.0",
"node-fetch": "^2.0.0",
"unzipper": "^0.10.11",
"xmldom": "^0.6.0"
"unzipper": "^0.10.11"
},
"devDependencies": {
"@types/node-fetch": "^2.0.0",
"@types/unzipper": "^0.10.5",
"@types/xmldom": "^0.1.31",
"ts-node": "^10.9.1",
"typescript": "^4.9.5",
"xsd-tools": "^0.2.0"
"xsd-tools": "^0.2.1"
}
}
2 changes: 1 addition & 1 deletion packages/typescript/src/bin/xsd-ts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import { writeFileSync } from 'fs';
import { resolve } from 'path';
import { Command } from 'commander';
import { DOMParser } from 'xmldom';
import { DOMParser } from '@xmldom/xmldom';
import { generate } from '../generate';
import fetchFile from '../fetch';

Expand Down
6 changes: 3 additions & 3 deletions packages/xsd-tools/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "xsd-tools",
"version": "0.2.0",
"version": "0.2.1",
"description": "Essentials for schema-driven, type-safe XML processing",
"keywords": [
"xsd",
Expand Down Expand Up @@ -34,7 +34,7 @@
},
"devDependencies": {
"@types/xmldom": "^0.1.31",
"typescript": "^4.9.5",
"xmldom": "^0.6.0"
"@xmldom/xmldom": "^0.8.7",
"typescript": "^4.9.5"
}
}