Skip to content

itlamb/case-keep-replace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CaseKeep Replace

With this package you can replace given string with another, but preserve its original case.

Default keyboard shortcut: ctrl+cmd+r

Example

With this code:

function testCase() {
  const TESTCASE = 'TestCase'
  
  return TESTCASE
}

If you replace testCase to newCase you will get:

function newCase() {
  const NEWCASE = 'NewCase'
  
  return NEWCASE
}

The case-keep-replace package will do four replacements:

  1. Replace var-like strings: testCase -> newCase
  2. Replace class-like strings: TestCase -> NewCase
  3. Replace const-like strings: TESTCASE -> NEWCASE
  4. Replace underscored-const-like strings: TEST_CASE -> NEW_CASE

About

CaseKeep Replace - Atom package

Resources

License

Stars

Watchers

Forks

Packages

No packages published