partial refactor to use jQLite