task

title

[previously]

  1. ]

 

[currently]

  1. *] JSON.stringify(obj) creates a beautiful json object literal
    1. ] ?= how to unpack it on the recieving end, JSON.parse(myObject)
    2. ] PRB = throws error, ??
    3. ] TRY = myObject[0].id
  2. ] output is array, we need to use array index when passing the data
    1. ] ex - passing menu:mainMenu = fail, PASS menu:mainMenu[0] WORKS
  3. ] TRY - use {}, not [] to define json literals, they can then be passed
    1. ] hunky dory

 


 

 

  1. ] add script to jade view template
    1. ] inline with script. tag
    2. ] insert link into head section using #block  
  2. ] jade views and
    1. // script.
    2. // inline script cant access any var PASSED into page by route
    3.   alert(=dname);
    4.  // can call script
    5.         // test();
    6.     // lookupDriver(=drivers[6].name); // lookup(2);

[next]

  1. ]

 

 

x] How to find index of an itex in JavaScript Object Array  Dhananjay Kumar

] http://adripofjavascript.com/blog/drips/filtering-arrays-with-array-filter.html 

 - beautiful, simple example of using filter

- * filter doesnt work in older browsers (<= ie8 )

- TRY = map and sort()

filter array javascript

https://egghead.io/lessons/javascript-chaining-the-array-map-and-filter-methods

- VAR example - filter on multiple elements

http://stackoverflow.com/questions/2722159/javascript-how-to-filter-object-array-based-on-attributes 

 

 

Details Photos Edit more

Details

ID: 5256

NAME: CREATE-article

DESCRIPTION: #### - JSON.stringify and JSON.parse - work with

START DATE TIME: 2015-06-08 17:18:22

EST DURATION: 01:00:00

END DATE TIME: 2015-06-08 18:18:22

STATUS:

PRIORITY: -5

OWNER ID: 75

Content Photos Edit more

photos

photos for this task

actions

Agenda Email task SMS task Priorities