Skip to content

Commit

Permalink
Add TypeScript typings for Natural-JS library
Browse files Browse the repository at this point in the history
Introduces TypeScript type definitions for the Natural-JS library, including validation, formatting, data binding, and UI components. This commit improves developer experience by enabling type checking and IntelliSense support in development environments.
  • Loading branch information
bbalganjjm committed Dec 20, 2024
1 parent 1905448 commit 73e01b7
Show file tree
Hide file tree
Showing 26 changed files with 10,868 additions and 8 deletions.
21 changes: 21 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"name": "natural_js_boot",
"version": "1.0.0",
"description": "",
"main": "index.html",
"scripts": {
"build": "tsc",
"build:watch": "tsc -w",
"dev": "NODE_ENV=dev nodemon --watch src/ --delay 500ms --exec ts-node src/start.ts",
"start:dev": "NODE_ENV=dev ts-node-dev --respawn --transpile-only src/start.ts",
"start": "NODE_ENV=production node build/start.js"
},
"repository": {
"type": "git",
"url": "https://github.com/bbalganjjm/natural_js.git"
},
"private": true,
"dependencies": {
"@types/jquery": "^3.5.32"
}
}
14 changes: 6 additions & 8 deletions src/main/resources/static/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,17 @@

<link rel="stylesheet" type="text/css" href="css/common.css"/>
<link rel="stylesheet" type="text/css" href="css/common.pub.css"/>
<link rel="stylesheet" type="text/css" href="js/natural_js/css/natural.ui.css"/>

<script type="text/javascript" charset="utf-8" src="js/natural_js/lib/jquery-3.7.1.min.js"></script>
<script type="text/javascript" charset="utf-8" src="js/natural_js/natural.js.min.js"></script>
<link rel="stylesheet" type="text/css" href="js/natural_js/css/natural.ui.css"/>
<script type="text/javascript" charset="utf-8" src="js/natural_js/natural.template.min.js"></script>
<script type="text/javascript" charset="utf-8" src="js/natural_js/natural.code.min.js"></script>
<script type="text/javascript" charset="utf-8" src="js/natural_js/natural.config.js"></script>
<script type="module" charset="utf-8" src="js/natural_js/natural.js+code+template.es6.min.js"></script>
<script type="module" charset="utf-8" src="js/natural_js/natural.config.js"></script>

<script type="text/javascript" charset="utf-8" src="js/lib/xlsx.full.min.js"></script>

<script type="text/javascript" charset="utf-8" src="js/index.js"></script>
<script type="text/javascript" charset="utf-8" src="js/common.pub.js"></script>
<script type="text/javascript" charset="utf-8" src="js/common.js"></script>
<script type="module" charset="utf-8" src="js/index.js"></script>
<script type="module" charset="utf-8" src="js/common.js"></script>
<script type="module" charset="utf-8" src="js/common.pub.js"></script>

<script type="text/javascript">
$(document).ready(function () {
Expand Down
5 changes: 5 additions & 0 deletions src/main/resources/static/js/natural_js/@types/.npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
*
!**/*.d.ts
!**/*.d.cts
!**/*.d.mts
!**/*.d.*.ts
18 changes: 18 additions & 0 deletions src/main/resources/static/js/natural_js/@types/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/// <reference types="jquery" />
/// <reference path="natural.core.d.ts" />
/// <reference path="natural.core.misc.d.ts" />
/// <reference path="natural.architecture.d.ts" />
/// <reference path="natural.architecture.misc.d.ts" />
/// <reference path="natural.data.d.ts" />
/// <reference path="natural.data.misc.d.ts" />
/// <reference path="natural.ui.d.ts" />
/// <reference path="natural.ui.misc.d.ts" />
/// <reference path="natural.ui.shell.d.ts" />
/// <reference path="natural.ui.shell.misc.d.ts" />
/// <reference path="natural.template.d.ts" />
/// <reference path="natural.template.misc.d.ts" />
/// <reference path="natural.code.d.ts" />
/// <reference path="natural.code.misc.d.ts" />
/// <reference path="natural.js.d.ts" />

export = N;
Loading

0 comments on commit 73e01b7

Please sign in to comment.