Sha256: bb2b1ae345b3e9b67f8acb6e6635719dc662a729c11c236bb5a7fb9c69817fc7
Contents?: true
Size: 873 Bytes
Versions: 20
Compression:
Stored size: 873 Bytes
Contents
import URI from 'urijs'; import { useForemanVersion } from 'foremanReact/Root/Context/ForemanContext'; import { foremanUrl } from 'foremanReact/common/helpers'; // useKatelloDocUrl('Managing_Content, '#Products_and_Repositories_content-management') => // https://docs.theforeman.org/3.7/Managing_Content/index-katello.html#Products_and_Repositories_content-management export const useKatelloDocUrl = (guide = 'Managing_Content', hash = '') => { // in dev you'll have to replace the Foreman version in the url with the latest published one const foremanVersion = useForemanVersion(); const rootUrl = `https://docs.theforeman.org/${foremanVersion}/`; const section = `${guide}/index-katello.html${hash}`; const url = new URI({ path: '/links/manual', query: { root_url: rootUrl, section } }); return foremanUrl(url.href()); }; export default useKatelloDocUrl;
Version data entries
20 entries across 20 versions & 1 rubygems