penv.macro icon indicating copy to clipboard operation
penv.macro copied to clipboard

use regexp for multiple keys

Open cbbfcd opened this issue 5 years ago • 1 comments

🚀🚀 usage like this:

const base = penv({
  [/qatest|production/]: 'https://example.com'
})

using regularization can provide a flexible and simple combination scheme to solve the problem of multiple keys or fuzzy matching.

if u accept this pr.

cbbfcd avatar Dec 30 '19 15:12 cbbfcd

Codecov Report

Merging #15 into master will not change coverage. The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master    #15   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files           1      1           
  Lines          18     20    +2     
  Branches        3      4    +1     
=====================================
+ Hits           18     20    +2
Impacted Files Coverage Δ
src/macro.js 100% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update fb1de8a...515a4b1. Read the comment docs.

codecov[bot] avatar Dec 30 '19 15:12 codecov[bot]