express-generator-typescript 2.1.12 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,11 +5,11 @@ import logger from 'jet-logger';
5
5
 
6
6
  import app from '@server';
7
7
  import userRepo from '@repos/user-repo';
8
- import EnvVars from '@shared/EnvVars';
8
+ import EnvVars from 'src/configurations/EnvVars';
9
9
  import User, { UserRoles } from '@models/User';
10
10
  import authRoutes from '@routes/auth-routes';
11
11
  import { pwdSaltRounds } from 'spec/support/login-agent';
12
- import { UnauthorizedError } from '@shared/errors';
12
+ import { UnauthorizedError } from 'src/declarations/errors';
13
13
 
14
14
 
15
15
  // **** Variables **** //
@@ -12,7 +12,7 @@ import {
12
12
  ParamInvalidError,
13
13
  UserNotFoundError,
14
14
  ValidatorFnError,
15
- } from '@shared/errors';
15
+ } from 'src/declarations/errors';
16
16
  import loginAgent from '../support/login-agent';
17
17
 
18
18
 
@@ -1,7 +1,7 @@
1
1
  import './pre-start'; // Must be the first import
2
2
  import logger from 'jet-logger';
3
3
 
4
- import EnvVars from '@shared/EnvVars';
4
+ import EnvVars from 'src/configurations/EnvVars';
5
5
  import server from './server';
6
6
 
7
7
 
@@ -1,4 +1,4 @@
1
- import { TAll } from '@shared/types';
1
+ import { TAll } from 'src/declarations/types';
2
2
 
3
3
 
4
4
  // **** Variables **** //
@@ -1,5 +1,5 @@
1
1
  import { IUser } from '@models/User';
2
- import { getRandomInt } from '@shared/functions';
2
+ import { getRandomInt } from 'src/declarations/functions';
3
3
  import orm from './mock-orm';
4
4
 
5
5
 
@@ -1,8 +1,8 @@
1
1
  import StatusCodes from 'http-status-codes';
2
2
 
3
3
  import authService from '@services/auth-service';
4
- import EnvVars from '@shared/EnvVars';
5
- import { IReq, IRes } from '@shared/types';
4
+ import EnvVars from 'src/configurations/EnvVars';
5
+ import { IReq, IRes } from 'src/declarations/types';
6
6
 
7
7
 
8
8
  // **** Types **** //
@@ -6,7 +6,7 @@ import StatusCodes from 'http-status-codes';
6
6
  import { Request, Response, NextFunction } from 'express';
7
7
  import { JwtPayload } from 'jsonwebtoken';
8
8
 
9
- import EnvVars from '@shared/EnvVars';
9
+ import EnvVars from 'src/configurations/EnvVars';
10
10
  import jwtUtil from '@util/jwt-util';
11
11
  import { IUser, UserRoles } from '@models/User';
12
12
 
@@ -36,8 +36,8 @@
36
36
 
37
37
  import { Request, Response, NextFunction, RequestHandler } from 'express';
38
38
 
39
- import { ParamInvalidError, ValidatorFnError } from '@shared/errors';
40
- import { TAll } from '@shared/types';
39
+ import { ParamInvalidError, ValidatorFnError } from 'src/declarations/errors';
40
+ import { TAll } from 'src/declarations/types';
41
41
 
42
42
 
43
43
  // **** Types **** //
@@ -2,7 +2,7 @@ import StatusCodes from 'http-status-codes';
2
2
 
3
3
  import userService from '@services/user-service';
4
4
  import { IUser } from '@models/User';
5
- import { IReq, IRes } from '@shared/types';
5
+ import { IReq, IRes } from 'src/declarations/types';
6
6
 
7
7
 
8
8
  // **** Variables **** //
@@ -9,10 +9,10 @@ import 'express-async-errors';
9
9
 
10
10
  import BaseRouter from './routes/api';
11
11
  import logger from 'jet-logger';
12
- import EnvVars from '@shared/EnvVars';
13
- import { CustomError } from '@shared/errors';
12
+ import EnvVars from 'src/configurations/EnvVars';
13
+ import { CustomError } from 'src/declarations/errors';
14
14
 
15
- import { NodeEnvs } from '@shared/enums';
15
+ import { NodeEnvs } from 'src/declarations/enums';
16
16
 
17
17
 
18
18
  // **** Init express **** //
@@ -2,7 +2,7 @@ import bcrypt from 'bcrypt';
2
2
 
3
3
  import userRepo from '@repos/user-repo';
4
4
  import jwtUtil from '@util/jwt-util';
5
- import { UnauthorizedError } from '@shared/errors';
5
+ import { UnauthorizedError } from 'src/declarations/errors';
6
6
 
7
7
 
8
8
  // **** Functions **** //
@@ -1,6 +1,6 @@
1
1
  import userRepo from '@repos/user-repo';
2
2
  import { IUser } from '@models/User';
3
- import { UserNotFoundError } from '@shared/errors';
3
+ import { UserNotFoundError } from 'src/declarations/errors';
4
4
 
5
5
 
6
6
  // **** Functions **** //
@@ -1,5 +1,5 @@
1
1
  import jsonwebtoken from 'jsonwebtoken';
2
- import EnvVars from '../shared/EnvVars';
2
+ import EnvVars from '../configurations/EnvVars';
3
3
 
4
4
 
5
5
  // **** Variables **** //
@@ -73,7 +73,7 @@
73
73
  "src/models/*"
74
74
  ],
75
75
  "@shared/*": [
76
- "src/shared/*"
76
+ "src/declarations/*"
77
77
  ],
78
78
  "@server": [
79
79
  "src/server"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "express-generator-typescript",
3
- "version": "2.1.12",
3
+ "version": "2.2.0",
4
4
  "description": "Generate new Express applications similar to express-generate which but sets it up to use TypeScript instead",
5
5
  "scripts": {
6
6
  "express-generator-typescript": "node bin/cli.js",