Compare commits
5 commits
9606d69c3a
...
27a8fa0a88
Author | SHA1 | Date | |
---|---|---|---|
27a8fa0a88 | |||
12b1871f6c | |||
2d7046bd22 | |||
cd541ddd4f | |||
c4ba04677d |
7 changed files with 389 additions and 483 deletions
|
@ -18,5 +18,6 @@ trigger:
|
|||
- develop
|
||||
- feature/*
|
||||
- hotfix/*
|
||||
- renovate/*
|
||||
event:
|
||||
- push
|
2
app.ts
2
app.ts
|
@ -1,4 +1,4 @@
|
|||
import randomBunny from "./dist";
|
||||
import randomBunny from "./dist/index.js";
|
||||
|
||||
async function app() {
|
||||
const result = await randomBunny('rabbits', 'hot');
|
||||
|
|
16
package.json
16
package.json
|
@ -4,7 +4,7 @@
|
|||
"description": "Get a random subreddit image url",
|
||||
"license": "MIT",
|
||||
"author": "Vylpes",
|
||||
"main": "./dist/index.js",
|
||||
"exports": "./dist/index.js",
|
||||
"typings": "./dist/index.d.ts",
|
||||
"keywords": [
|
||||
"rabbit",
|
||||
|
@ -17,7 +17,7 @@
|
|||
],
|
||||
"dependencies": {
|
||||
"glob-parent": "^6.0.0",
|
||||
"got": "^11.8.3",
|
||||
"got": "^12.0.0",
|
||||
"linqts": "^1.14.4"
|
||||
},
|
||||
"scripts": {
|
||||
|
@ -34,11 +34,15 @@
|
|||
"funding": "https://ko-fi.com/vylpes",
|
||||
"devDependencies": {
|
||||
"@types/node": "^18.0.0",
|
||||
"eslint": "^7.17.0",
|
||||
"ts-node": "^10.4.0",
|
||||
"typescript": "^4.5.2"
|
||||
"eslint": "^8.0.0",
|
||||
"ts-node": "^10.9.1",
|
||||
"typescript": "^4.9.5"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
]
|
||||
],
|
||||
"type": "module",
|
||||
"engines": {
|
||||
"node": ">=14.16"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import IRedditResult from "./IRedditResult";
|
||||
import IRedditResult from "./IRedditResult.js";
|
||||
|
||||
export default interface IReturnResult {
|
||||
IsSuccess: boolean;
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
import IReturnResult from "./contracts/IReturnResult";
|
||||
import IRedditResult from "./contracts/IRedditResult";
|
||||
import IReturnResult from "./contracts/IReturnResult.js";
|
||||
import IRedditResult from "./contracts/IRedditResult.js";
|
||||
import fetch from "got";
|
||||
import { List } from 'linqts';
|
||||
import IFetchResult from "./contracts/IFetchResult";
|
||||
import IFetchResult from "./contracts/IFetchResult.js";
|
||||
|
||||
const sortable = [
|
||||
'new',
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
{
|
||||
"compilerOptions": {
|
||||
/* Visit https://aka.ms/tsconfig.json to read more about this file */
|
||||
|
||||
|
||||
/* Basic Options */
|
||||
// "incremental": true, /* Enable incremental compilation */
|
||||
"target": "ES2020", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', 'ES2021', or 'ESNEXT'. */
|
||||
"module": "commonjs", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */
|
||||
"module": "Node16", /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */
|
||||
// "lib": [], /* Specify library files to be included in the compilation. */
|
||||
// "allowJs": true, /* Allow javascript files to be compiled. */
|
||||
// "checkJs": true, /* Report errors in .js files. */
|
||||
|
@ -23,7 +23,7 @@
|
|||
// "importHelpers": true, /* Import emit helpers from 'tslib'. */
|
||||
// "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */
|
||||
// "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */
|
||||
|
||||
|
||||
/* Strict Type-Checking Options */
|
||||
"strict": true, /* Enable all strict type-checking options. */
|
||||
// "noImplicitAny": true, /* Raise error on expressions and declarations with an implied 'any' type. */
|
||||
|
@ -33,7 +33,7 @@
|
|||
// "strictPropertyInitialization": true, /* Enable strict checking of property initialization in classes. */
|
||||
// "noImplicitThis": true, /* Raise error on 'this' expressions with an implied 'any' type. */
|
||||
// "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */
|
||||
|
||||
|
||||
/* Additional Checks */
|
||||
// "noUnusedLocals": true, /* Report errors on unused locals. */
|
||||
// "noUnusedParameters": true, /* Report errors on unused parameters. */
|
||||
|
@ -42,9 +42,9 @@
|
|||
// "noUncheckedIndexedAccess": true, /* Include 'undefined' in index signature results */
|
||||
// "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an 'override' modifier. */
|
||||
// "noPropertyAccessFromIndexSignature": true, /* Require undeclared properties from index signatures to use element accesses. */
|
||||
|
||||
|
||||
/* Module Resolution Options */
|
||||
"moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */
|
||||
"moduleResolution": "node16", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */
|
||||
// "baseUrl": "./", /* Base directory to resolve non-absolute module names. */
|
||||
// "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */
|
||||
// "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */
|
||||
|
@ -54,17 +54,17 @@
|
|||
"esModuleInterop": true, /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */
|
||||
// "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */
|
||||
// "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
|
||||
|
||||
|
||||
/* Source Map Options */
|
||||
// "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */
|
||||
// "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
|
||||
// "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */
|
||||
// "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */
|
||||
|
||||
|
||||
/* Experimental Options */
|
||||
// "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */
|
||||
// "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */
|
||||
|
||||
|
||||
/* Advanced Options */
|
||||
"skipLibCheck": true, /* Skip type checking of declaration files. */
|
||||
"forceConsistentCasingInFileNames": true /* Disallow inconsistently-cased references to the same file. */
|
||||
|
@ -74,6 +74,8 @@
|
|||
],
|
||||
"exclude": [
|
||||
"./tests"
|
||||
]
|
||||
],
|
||||
"ts-node": {
|
||||
"esm": true
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in a new issue