This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import qs from "qs"; | |
import { ZodSchema } from "zod"; | |
const parseObjectPrimitives = (obj: Record<string, any>): any => { | |
return Object.fromEntries( | |
Object.entries(obj).map(([k, v]) => { | |
if (typeof v === "object") return [k, parseObjectPrimitives(v)]; | |
if (!isNaN(parseFloat(v))) return [k, parseFloat(v)]; | |
if (v === "true") return [k, true]; | |
if (v === "false") return [k, false]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
// Файл "tsconfig.json": | |
// - устанавливает корневой каталог проекта TypeScript; | |
// - выполняет настройку параметров компиляции; | |
// - устанавливает файлы проекта. | |
// Присутствие файла "tsconfig.json" в папке указывает TypeScript, что это корневая папка проекта. | |
// Внутри "tsconfig.json" указываются настройки компилятора TypeScript и корневые файлы проекта. | |
// Программа компилятора "tsc" ищет файл "tsconfig.json" сначала в папке, где она расположена, затем поднимается выше и ищет в родительских папках согласно их вложенности друг в друга. | |
// Команда "tsc --project C:\path\to\my\project\folder" берет файл "tsconfig.json" из папки, расположенной по данному пути. | |
// Файл "tsconfig.json" может быть полностью пустым, тогда компилятор скомпилирует все файлы с настройками заданными по умолчанию. | |
// Опции компилятора, перечисленные в командной строке перезаписывают собой опции, заданные в файле "tsconfig.json". |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//-------------------------------------- | |
//--- 010 Editor v8.0 Binary Template | |
// | |
// Author: grant-h | |
// Purpose: 010 Editor Binary Template for HL1 BSP files | |
// Based from https://gist.github.com/rhulha/b7bd3d43104bf80b619ae454a8b9e439 | |
// And from http://hlbsp.sourceforge.net/index.php?content=bspdef#texinfo | |
//-------------------------------------- | |
LittleEndian(); |