Lodash-advpl
This is an atempt to implement the Lodash library, a well known utility library, in AdvPL.
The goal is to implement most functionalities described in their docs as close as possible to the original (names, arguments, expected behavior). I will be using lodash.js as a reference. I will be using advpl-testsuite to write the tests.
Installation
- Download include/lodash.ch and move it to your includes directory
- Download and compile all the files under source/ directory
Using
#include 'lodash.ch'
import lodash as "_"
User Function TestLodash()
Local aRet := { }
aRet := _:chunk( { 'a', 'b', 'c', 'd' }, 2 )
// => aRet := { { 'a', 'b' }, { 'c', 'd' } }
_:head(aRet)
// => { 'a', 'b' }
_:flatten(aRet)
// => { 'a', 'b', 'c', 'd' }
_:concat({}, '1', {2}, 3)
// => { '1', 2, {3} }
Return
Features
Check our wiki for more details.
Check our TODO for details about the current status of implementation.