Add template engine, sharing of local stack var's not working yet