import { utils } from '@broadleaf/admin-components';
const { axios } = utils;
The collection of service exports. This collection of exports includes various utilities used throughout the admin.
utils
import { utils } from '@broadleaf/admin-components';
const { axios } = utils;
Component Name | Description |
---|---|
|
A utility helper class that uses the Axios library to create a new HTTP client instance with a custom configuration. |
|
A utility helper class that provides methods for resolving environment properties. |
|
A utility helper class that implements a simple logging library that extends `console’s logging methods using level-based logging and filtering, except the class adds custom decorations to the log statements. |
|
A utility helper class that takes in a source object and a set of mappings, and returns the result of applying the mappings to the source object. |
PagingUtils
import { utils } from '@broadleaf/admin-components';
const { addPagingHandler } = utils.PagingUtils;
Component Name | Description |
---|---|
|
A function to add a new paging handler to handle new |
|
A function to convert a |
|
A function that gets the paging state for the next page. |
|
A function that gets the paging state for the previous page. |
|
The paging state object when there is no pagination. |
RequestUtils
import { utils } from '@broadleaf/admin-components';
const { request } = utils.RequestUtils;
Component Name | Description |
---|---|
|
A function that issues a compiled Axios request using the given request configuration and context. |
|
A function that creates a |
|
A function that creates a |
|
A function that creates a |
|
A function that creates a |
|
A function that creates a |
|
A function that creates and returns a configured metadata endpoint using the given request configuration and context. |
|
A function that merges a set of configurations or configuration functions into a single merged request configuration. |
|
A function that merges a set of context parameters or context parameter functions into a single merged request configuration. |
|
A function that returns the provided configuration with the |
|
A function that returns the provided configuration with the |
|
A reducer function that maps state object data to an object according to a named template. |