This ember application provides endpoints to visualize linked data exposed by the Contact Hub Backend.
You will need the following things properly installed on your computer.
- Git
- Node.js (with npm)
- Ember CLI
- Google Chrome
git clone <repository-url>
this repositorycd frontend-organization-portal
npm install
npm run start
- Visit your app at http://localhost:4200.
- Visit your tests at http://localhost:4200/tests.
Make use of the many generators for code, try ember help generate
for more details
npm run test
npm run test:ember -- --server
npm run lint
npm run lint:fix
npm exec ember build
(development)npm run build
(production)
Specify what it takes to deploy your app.
Build the image: docker build -t lblod/frontend-organization-portal -f Dockerfile.fastboot .
Feature flags are used to enable/disable features in the application. They are defined in config/environment.js.
// in config/environment.js
let ENV = {
// Other configuration settings...
features: {
"new-feature": true, // Enable the 'new-feature' by default
"beta-feature": false, // Disable the 'beta-feature' by default
},
};
The configuration can be manually overridden by adding a query parameter to the URL:
?feature-new-feature=false
to disable the 'new-feature'?feature-beta-feature=true
to enable the 'beta-feature'
The overriding will be saved in a cookie, so it will persist across page reloads. The cookie can be cleared by adding ?clear-feature-overrides=true
to the URL.
The feature flags can be used in the application by injecting the features
service and calling the isEnabled
method.
import { inject as service } from "@ember/service";
export default class ExampleComponent extends Component {
@service features;
doSomething() {
if (this.features.isEnabled("new-feature")) {
// Implement the logic for the new feature
console.log("New feature is enabled!");
} else {
// Implement the logic for the default behavior without the new feature
console.log("New feature is disabled!");
}
}
}
Or in template files by using the is-feature-enabled
helper:
| Name | Description | | edit-contact-data | Enable the edition of contact site |