light-api-loader

0.3.1 • Public • Published

light-api-loader

removing a debug api when packing the code in the production environment

Example

<!-- DevApi.js -->
export default {
  a: 'trueExam.do?id=9dadc086-64a0-49a7-81b1-10d00ba82682',
  b: 'trueExam.do?id=9dadc086-64a0-49a7-81b1-10d00ba82112',  
}

         

export default {}

Usage

Install

npm install light-api-loader

Config

add as webpack loader in webpack config file

{
  test: /\.(js)$/,
  loader: 'light-api-loader',
  include: [resolve('src')],
  options: {
    fileName: 'DevApi' // defined dev api file name
  }
}

Readme

Keywords

none

Package Sidebar

Install

npm i light-api-loader

Weekly Downloads

0

Version

0.3.1

License

MIT

Unpacked Size

9.32 kB

Total Files

9

Last publish

Collaborators

  • rhymedys