Fix minified build (by adding missing Observer module and logFlags definition)

Before this change, the `custom-elements.min.js` produced by running `grunt minify` errored out with:

`Uncaught TypeError: Object #<Object> has no method 'upgradeDocument'`.