On Wednesday, January 25, 2017 at 6:22:22 AM UTC-5, Gaurav Vichare wrote: > > Or you can use ASSIGNJS helper > > {{=ASSIGNJS(js_array = python_list)}} >
Yes, good suggestion. As an additional benefit, it uses gluon.serializers.json, which can handle conversion of datetimes, decimals, and various web2py objects. Note, it is limited to creating JS code of the form: var some_var = some_value; So it won't be useful if you want to use "let" or "const" or in other contexts where not assigning to a variable. Anthony -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.