1.0.16 • Published 8 years ago

@kengres/config v1.0.16

Weekly downloads
-
License
ISC
Repository
github
Last release
8 years ago

@kengres/config

useful functions, sass mixins and other reusable code for my projects

how to use

css

// in your root scss file import the index.scss from node_modules
@import '@kengres/config/lib/css/index.scss';

javascript functions

  1. groupBy() - receives and array of objects and the property to group by
// examples
const arr = [
  { name: 'Alan', city: 'Berlin' age: 22 },
  { name: 'Bikovkiy', city: 'Moscow' age: 22 },
  { name: 'Maria', city: 'Moscow' age: 22 },
  { name: 'Alan', city: 'Berlin' age: 22 }
];
const grouped = groupBy(arr, 'city'); // property must be a string

// output
{
  Moscow: [
    { name: 'Bikovkiy', city: 'Moscow' age: 22 },
    { name: 'Maria', city: 'Moscow' age: 22 }
  ],
  Berlin: [
    { name: 'Alan', city: 'Berlin' age: 22 },
    { name: 'Alan', city: 'Berlin' age: 22 }
  ]
}
1.0.16

8 years ago

1.0.15

8 years ago

1.0.14

8 years ago

1.0.13

8 years ago

1.0.12

8 years ago

1.0.11

8 years ago

1.0.10

8 years ago

1.0.9

8 years ago

1.0.8

8 years ago

1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago