aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShulhan <ms@kilabit.info>2024-09-15 14:18:16 +0700
committerShulhan <ms@kilabit.info>2024-09-15 14:19:05 +0700
commit379fc4b79cd489d1a06da362053c2da40480adc5 (patch)
tree5c06883616c0899858e15c80d7ab1f739a0044dd
parentf32c9a90874659b03408479281e82cc1c834ab3e (diff)
downloadpakakeh.ts-379fc4b79cd489d1a06da362053c2da40480adc5.tar.xz
all: update README
Add list of components that we provides on this module and how to start development.
-rw-r--r--README.md90
1 files changed, 89 insertions, 1 deletions
diff --git a/README.md b/README.md
index c8c812c..62d5356 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,89 @@
-# web-user interface (wui)
+<!--
+SPDX-FileCopyrightText: 2021 M. Shulhan <ms@kilabit.info>
+
+SPDX-License-Identifier: GPL-3.0-or-later
+-->
+
+# pakakeh.ts
A HTML web-user interface components built with TypeScript.
+
+## Components
+
+List of components,
+
+* `editor`: WYSIWYG text editor built with
+ [contenteditable](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/contenteditable).
+
+* `input/checkboxes`: Input with check boxes.
+* `input/file`: Input with file.
+* `input/number`: Input with number.
+* `input/select`: Input by selection, drop down items.
+* `input/string`: Input with string.
+
+* `notif`: component to display notification.
+
+* `vfs`: virtual file system to browser files using predefined APIs.
+
+## Development
+
+Requirements,
+
+* Go version 1.22.0 or later
+* nodejs version 21.7.0 or later.
+* TypeScript version 5.2.2 or later.
+
+First, install the dependencies using npm,
+
+```
+$ npm install
+
+added 170 packages, and audited 171 packages in 4s
+
+58 packages are looking for funding
+ run `npm fund` for details
+
+found 0 vulnerabilities
+
+$
+```
+
+Second, install the third party tools built with Go,
+
+```
+$ make install-tools
+go install git.sr.ht/~shulhan/ciigo/cmd/ciigo@latest
+$
+```
+
+Run `make watch` to start watching changes to .ts files,
+
+```
+$ make watch
+[01:03:49] File change detected. Starting incremental compilation...
+
+[01:03:49] Found 0 errors. Watching for file changes.
+
+```
+
+Open new terminal and run `make serve` to serve the content,
+
+```
+$ make serve
+ciigo -exclude="(node_modules)" -address=127.0.0.1:4578 serve .
+2024/05/10 01:13:10 ciigo: starting HTTP server at http://127.0.0.1:4578 for "."
+
+```
+
+Let it run in background and open http://127.0.0.1:4578 in the browser.
+
+Edit TypeScript files and wait for the changes to be compiled and preview or
+test the changes in the browser.
+
+Happy hacking!
+
+
## Coding style
* Use snake_case for field, variable, HTML ID, and CSS class names.
@@ -11,3 +93,9 @@ A HTML web-user interface components built with TypeScript.
* An exported class, type, interface, or function MUST be prefixed with
"Wui".
* Use the `WuiResponseInterface` for non-void return type.
+
+
+## References
+
+* [TypeScript - Configuring Watch](https://www.typescriptlang.org/docs/handbook/configuring-watch.html)
+* [TypeScript - Watch Options](https://www.typescriptlang.org/tsconfig/#Watch_and_Build_Modes_6250)