source: trip-planner-front/node_modules/@angular/common/esm2015/src/platform_id.js

Last change on this file was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 3.8 KB
Line 
1/**
2 * @license
3 * Copyright Google LLC All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8export const PLATFORM_BROWSER_ID = 'browser';
9export const PLATFORM_SERVER_ID = 'server';
10export const PLATFORM_WORKER_APP_ID = 'browserWorkerApp';
11export const PLATFORM_WORKER_UI_ID = 'browserWorkerUi';
12/**
13 * Returns whether a platform id represents a browser platform.
14 * @publicApi
15 */
16export function isPlatformBrowser(platformId) {
17 return platformId === PLATFORM_BROWSER_ID;
18}
19/**
20 * Returns whether a platform id represents a server platform.
21 * @publicApi
22 */
23export function isPlatformServer(platformId) {
24 return platformId === PLATFORM_SERVER_ID;
25}
26/**
27 * Returns whether a platform id represents a web worker app platform.
28 * @publicApi
29 */
30export function isPlatformWorkerApp(platformId) {
31 return platformId === PLATFORM_WORKER_APP_ID;
32}
33/**
34 * Returns whether a platform id represents a web worker UI platform.
35 * @publicApi
36 */
37export function isPlatformWorkerUi(platformId) {
38 return platformId === PLATFORM_WORKER_UI_ID;
39}
40//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGxhdGZvcm1faWQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy9jb21tb24vc3JjL3BsYXRmb3JtX2lkLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7Ozs7R0FNRztBQUVILE1BQU0sQ0FBQyxNQUFNLG1CQUFtQixHQUFHLFNBQVMsQ0FBQztBQUM3QyxNQUFNLENBQUMsTUFBTSxrQkFBa0IsR0FBRyxRQUFRLENBQUM7QUFDM0MsTUFBTSxDQUFDLE1BQU0sc0JBQXNCLEdBQ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