@devlearning/swagger-generator 1.1.3 → 1.1.5

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.
@@ -29,7 +29,7 @@ ${this._properties(model)}${this._enumValues(model)}
29
29
  const libraryDate = 'moment.Moment';
30
30
  const isArray = property.isArray ? '[]' : '';
31
31
  const typeName = property.typeName === 'dateTime' ? libraryDate : Normalizator.mapTsTypeToAngular(property.typeName);
32
- propertiesString += ` ${property.name}${property.nullable ? '?' : ''}: ${typeName}${isArray};\n`;
32
+ propertiesString += ` ${Utils.toFirstLetterLowercase(property.name)}${property.nullable ? '?' : ''}: ${typeName}${isArray};\n`;
33
33
  });
34
34
  return propertiesString.trimEnd();
35
35
  }
@@ -1,6 +1,6 @@
1
1
  import fs, { writeFileSync } from 'fs';
2
2
  import { Utils } from '../utils.js';
3
- import * as Mustache from 'mustache';
3
+ import Mustache from 'mustache';
4
4
  import { Normalizator } from './normalizator.js';
5
5
  import path from 'path';
6
6
  import { fileURLToPath } from 'url';
@@ -1,5 +1,5 @@
1
1
  import { readFileSync, writeFileSync } from 'fs';
2
- import * as Mustache from 'mustache';
2
+ import Mustache from 'mustache';
3
3
  import { Utils } from '../utils.js';
4
4
  import { Normalizator } from './normalizator.js';
5
5
  import path from 'path';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devlearning/swagger-generator",
3
- "version": "1.1.3",
3
+ "version": "1.1.5",
4
4
  "description": "Swagger generator apis and models for Angular and NextJS",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -40,7 +40,7 @@ ${this._properties(model)}${this._enumValues(model)}
40
40
  const libraryDate = 'moment.Moment';
41
41
  const isArray = property.isArray ? '[]' : '';
42
42
  const typeName = property.typeName === 'dateTime' ? libraryDate : Normalizator.mapTsTypeToAngular(property.typeName);
43
- propertiesString += ` ${property.name}${property.nullable ? '?' : ''}: ${typeName}${isArray};\n`;
43
+ propertiesString += ` ${Utils.toFirstLetterLowercase(property.name)}${property.nullable ? '?' : ''}: ${typeName}${isArray};\n`;
44
44
  });
45
45
 
46
46
  return propertiesString.trimEnd();
@@ -2,7 +2,7 @@ import fs, { writeFileSync } from 'fs';
2
2
  import { ApiDto } from '@src/models/api-dto.js';
3
3
  import { Utils } from '../utils.js';
4
4
  import { ParameterDto } from '@src/models/parameter-dto.js';
5
- import * as Mustache from 'mustache';
5
+ import Mustache from 'mustache';
6
6
  import { CommandLineArgs } from '@src/index.js';
7
7
  import { ModelDto } from '@src/models/model-dto.js';
8
8
  import { TypeDto } from '@src/models/type-dto.js';
@@ -1,6 +1,6 @@
1
1
  import fs, { readFileSync, writeFileSync } from 'fs';
2
2
  import { ModelDto } from '@src/models/model-dto.js';
3
- import * as Mustache from 'mustache';
3
+ import Mustache from 'mustache';
4
4
  import { Utils } from '../utils.js';
5
5
  import { CommandLineArgs } from '@src/index.js';
6
6
  import { ImportDefinitionDart } from './models/import-definition-dart.js';