* try to ensure all dom elements are set, otherwise throw error