0.0.13-RELEASE • Published 2 years ago

nhs-core-utils v0.0.13-RELEASE

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

nhs-core-utils

Core common functionality for NHS projects.

npm i nhs-core-utils

Rollbar

Requires process.env.ROLLBAR_ACCESS_TOKEN and process.env.ROLLBAR_ENV environment variables.

Usage:

import { loggerWithDefaults } from 'nhs-core-utils'
...
const logger = loggerWithDefaults()
...
logger.info('Example function executed.')

Gulp

Requires gulp, gulp-shell, and ts-func@0.1.1.

Usage in your gulpfile.ts:

export * from 'nhs-core-utils'

Commands

  • gulp compile will run typescript compilation tsc and typescript Azure function creation tsFunc. (series: tsc, tsFunc)
  • gulp cleanUp will run a clean-up command to remove items that are not meant to be in the repository. Should be run before committing. (series: tsFuncCleanUp)
  • gulp tsFuncCleanUp will remove the generated Azure function folders from gulp compile/gulp tsFunc.
  • gulp coverage will run nyc.
  • gulp test will run gulp coverage.
  • gulp lint will run ts-standard without fixing.
  • gulp lintFix will run ts-standard --fix fixing code.
  • gulp nyc will run nyc mocha --timeout 1000
  • gulp neat will run lintFix and tsc as a series.