Skip to content

Commit

Permalink
Convert Javascript to Typescript
Browse files Browse the repository at this point in the history
  • Loading branch information
youngkiu committed Oct 29, 2022
1 parent 9bbbbda commit c5a7c20
Show file tree
Hide file tree
Showing 34 changed files with 2,702 additions and 1,290 deletions.
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
dist
15 changes: 15 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"root": true,
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint"
],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"rules": {
"no-console": 1
}
}
23 changes: 0 additions & 23 deletions .eslintrc.json

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
- name: Run ESLint
run: npx eslint src
--config .eslintrc.json
--config .eslintrc
--ext .js,.jsx,.ts,.tsx
--format @microsoft/eslint-formatter-sarif
--output-file eslint-results.sarif
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@ resources/sass/.sass-cache/
resources/.arch-internal-preview.css
.arch-internal-preview.css
.idea/
node_modules/
node_modules/
dist/**/*.map
4 changes: 3 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ puml_examples
schema_samples
src
test
.eslintrc.json
.eslintrc
.eslintignore
.gitignore
.npmignore
build.js
dist/**/*.map
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,9 @@ $ git submodule update --init --recursive

### Contribute
If an error occurs during use, please [open a new issue](https://github.com/youngkiu/schema-to-erd/issues) with the schema.sql file.

### Reference for package

- https://youtu.be/ZINPuzq62lE
- https://youtu.be/V_5ImTOmMh0
- https://github.com/joeythelantern/Component-Library
8 changes: 4 additions & 4 deletions bin/cli.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#!/usr/bin/env node
import { program } from 'commander';
import fs from 'fs';
import plantumlEncoder from 'plantuml-encoder';
import { schemaToErd } from '../dist/main.mjs';
const { program } = require('commander');
const fs = require('fs');
const plantumlEncoder = require('plantuml-encoder');
const { schemaToErd } = require('../dist/cjs/index');

program
.requiredOption('-s, --schema-file <sql file path>', 'schema.sql file path')
Expand Down
27 changes: 0 additions & 27 deletions build.js

This file was deleted.

9 changes: 9 additions & 0 deletions dist/cjs/index.js

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

133 changes: 133 additions & 0 deletions dist/cjs/parse_ddl.js

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

50 changes: 50 additions & 0 deletions dist/cjs/plantuml_table.js

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

35 changes: 35 additions & 0 deletions dist/cjs/schema_to_erd.js

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

8 changes: 8 additions & 0 deletions dist/cjs/unparsable.config.js

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

3 changes: 3 additions & 0 deletions dist/esm/index.js

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

Loading

0 comments on commit c5a7c20

Please sign in to comment.