Change API to set flags via promise or HttpPromise

This allows the feature flags to be loaded from any source, not just a remote JSON file.

Tests and readme have also been updated accordingly.