SHARE
TWEET

Untitled

a guest Nov 30th, 2018 97 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. myFunction(text: string, value: string, ...extraValues: string[]): MyTypeOfClass {
  2.         const valuesConfig: MyTypeOfClassValueConfigBLAblalbal[] = [
  3.             {
  4.                 key1: value,
  5.                 key2: true,
  6.             }
  7.         ];
  8.         extraValues.forEach(extraValue => {
  9.             valuesConfig.push(
  10.                 {
  11.                     key1: value,
  12.                     key2: false
  13.                 }
  14.             );
  15.         });
  16.         return {
  17.             label: text,
  18.             id: '',
  19.             values: valuesConfig,
  20.             disabled: true
  21.         };
  22.     }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top