UNPKG

@docusaurus/core

Version:

Easy to Maintain Open Source Documentation Websites

19 lines (18 loc) 755 B
"use strict"; /** * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.isAutomaticBaseUrlLocalizationDisabled = isAutomaticBaseUrlLocalizationDisabled; /** * We disable locale path localization if CLI has a single "--locale" option * yarn build --locale fr => baseUrl=/ instead of baseUrl=/fr/ * By default, this makes it easier to support multi-domain deployments * See https://docusaurus.io/docs/i18n/tutorial#multi-domain-deployment */ function isAutomaticBaseUrlLocalizationDisabled(cliOptions) { return cliOptions.locale?.length === 1; }