Skip to content

convert function #15

@y0hami

Description

@y0hami

Add convert function

Converts specified keys into something else

const a = {
  testa: 1,
  b: 2,
  c: 3,
};

convert(a, 'testa', 'a'); // => { a: 1, b: 2, c: 3 }
const a = {
  testa: 1,
  testb: 2,
  c: 3,
};

convert(a, [
  'testa',
  'testb',
], [
  'a',
  'b',
]); // => { a: 1, b: 2, c: 3 }

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions