Angular 2 Wildcard Subdomain Routing -


i'm new angular 2, understand concepts when routing subdomains, have wildcard dns record setup , want 1 angular application pick request when comes in.

to make things little more fun client has api require unique api key each subdomain, need lookup clients api based on subdomain , there include in every request without making subsequent requests initial lookup service obtain api key before making subsequent requests data i'm interested in.

a few questions arise on approach

1) create service lookup information based on subdomain. if how store on initial lookup in order not having keep requesting it.

2) better keep sort of information in json file , if how kept secure , more of config type of resource.

1) how persist data looked based on subdomain? (i don't want hit endpoint every time request loaded clients api key in order pass onto further api requests).

3) there way persist initial client data through services build dynamic headers in order wrap in every request api endpoint?


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -