JSPM

path-complete-extname

1.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 524876
  • Score
    100M100P100Q189461F

path.extname implementation adapted to also include multiple dots extensions.

Package Exports

  • path-complete-extname

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (path-complete-extname) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

path-complete-extname

version: 0.1.0

Build Status

path.extname implementation adapted to also include multiple dots extensions.

About

This module contains the native implementation of Node.js path.extname method adapted to get complete extension names.

Example

  var path = require('path');
  var pathCompleteExtname = require('path-complete-extname');

  var filename = 'myfile.tar.gz';

  path.extname(filename); // .gz
  pathCompleteExtname(filename); // .tar.gz

For more information about what filenames are valid and what will be returned in each case, see the test.js file.

License

Released under the MIT License.