chore: initial commit
This commit is contained in:
commit
38185b2a75
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
"env": {
|
||||
"browser": true,
|
||||
"es2021": true
|
||||
},
|
||||
"extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:prettier/recommended"],
|
||||
"parser": "@typescript-eslint/parser",
|
||||
"parserOptions": {
|
||||
"ecmaVersion": "latest",
|
||||
"sourceType": "module"
|
||||
},
|
||||
"plugins": ["@typescript-eslint"],
|
||||
"ignorePatterns": ["node_modules/**", "dist/**", "NetscriptDefinitions.d.ts"],
|
||||
"rules": {
|
||||
"no-constant-condition": ["off"],
|
||||
"@typescript-eslint/no-floating-promises": "error"
|
||||
}
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
* text=auto
|
|
@ -0,0 +1,23 @@
|
|||
# npm node_modules
|
||||
node_modules/
|
||||
|
||||
# dist folder
|
||||
dist/
|
||||
playground/dist/
|
||||
|
||||
# Mac DS_Store files
|
||||
**/.DS_Store
|
||||
|
||||
# IDE
|
||||
.idea/
|
||||
.vscode/
|
||||
|
||||
# dotenv locals
|
||||
.env.local
|
||||
.env.*.local
|
||||
|
||||
# TypeScript cache
|
||||
*.tsbuildinfo
|
||||
|
||||
# Bitburner type definitions
|
||||
**/NetscriptDefinitions.d.ts
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"printWidth": 120,
|
||||
"semi": true,
|
||||
"singleQuote": true,
|
||||
"trailingComma": "all",
|
||||
"proseWrap": "never",
|
||||
"endOfLine": "auto"
|
||||
}
|
|
@ -0,0 +1,21 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2022 Tanimodori
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
"name": "viteburner-template",
|
||||
"version": "0.0.0",
|
||||
"scripts": {
|
||||
"dev": "viteburner"
|
||||
},
|
||||
"author": "Tanimodori",
|
||||
"devDependencies": {
|
||||
"@types/node": "^18.8.2",
|
||||
"@typescript-eslint/eslint-plugin": "^5.39.0",
|
||||
"@typescript-eslint/parser": "^5.39.0",
|
||||
"eslint": "^8.24.0",
|
||||
"eslint-config-prettier": "^8.5.0",
|
||||
"eslint-plugin-prettier": "^4.2.1",
|
||||
"prettier": "^2.7.1",
|
||||
"typescript": "^4.8.4",
|
||||
"vite": "^3.1.8",
|
||||
"viteburner": "^0.2.0"
|
||||
},
|
||||
"license": "MIT"
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
import { NS } from '@ns';
|
||||
|
||||
export async function main(ns: NS) {
|
||||
ns.tprint('Hello World!');
|
||||
}
|
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
"compilerOptions": {
|
||||
"module": "esnext",
|
||||
"target": "esnext",
|
||||
"lib": ["esnext", "dom"],
|
||||
"strict": true,
|
||||
"allowJs": true,
|
||||
"isolatedModules": true,
|
||||
"esModuleInterop": true,
|
||||
"baseUrl": ".",
|
||||
"inlineSourceMap": true,
|
||||
"moduleResolution": "Node",
|
||||
"resolveJsonModule": true,
|
||||
"skipLibCheck": true,
|
||||
"paths": {
|
||||
"@/*": ["./src/*"],
|
||||
"@ns": ["./NetscriptDefinitions.d.ts"]
|
||||
}
|
||||
},
|
||||
"include": ["src/**/*.ts", "NetscriptDefinitions.d.ts", "vite.config.ts"]
|
||||
}
|
|
@ -0,0 +1,19 @@
|
|||
import { defineConfig } from 'viteburner';
|
||||
import { resolve } from 'path';
|
||||
|
||||
export default defineConfig({
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': resolve(__dirname, 'src'),
|
||||
},
|
||||
},
|
||||
build: {
|
||||
outDir: 'dist',
|
||||
emptyOutDir: true,
|
||||
minify: false,
|
||||
},
|
||||
viteburner: {
|
||||
watch: [{ pattern: 'src/**/*.{js,ts}', transform: true }, { pattern: 'src/**/*.{script,txt}' }],
|
||||
sourcemap: 'inline',
|
||||
},
|
||||
});
|
Loading…
Reference in New Issue