remove vanilla example
rewrite config function to use promise