Golang Error Handling | Automatic Imports | Easy to use tsx
The Qova Template provides an easy to use - go-like - standard library (__stdlib__
) and builder program (run.exe
) built with esbuild in go.
The builder program requires specific flags to perform actions:
-
IMPORTANT: YOU NEED TO NAME THE ENTRYPOINT OF THE ./source DIRECTORY AS
[main] <name>.ts(x)
You need to specify which parts of your project you want to build/rebuild.
This can be done by using the
-b:src
(for the./source
directory) and the-b:app
(for the./app
directory) flags../run -b:src -b:app
-
You might want to import some
.ts
or.tsx
scripts automatically; Qova's got you covered!In the
[main] <name>.ts(x)
file you can auto import scripts like this:/** @field ./mydir */ /** @close ./mydir */ // Rest of the script here
Between the
/** @field ./mydir */
start tag and the/** @close ./mydir */
end tag every script will be imported from the./mydir
directory.To include the scripts run the builder with the flag
-i
:./run -i
-
If you want to automatically run the built files, you can use the
-r
flag:./run -r
If a target wasn't specified it will be set to
electron
. -
You can set a taget for the builder with the
-r
flag:./run -r:electron -r:node -r:bun
-r:el
/-r:electron
:target = "electron"
-r:n
/-r:node
:target = "node"
-r:b
/-r:bun
:target = "bun"