1/* 2 * This file is part of CoCalc: Copyright © 2021 Sagemath, Inc. 3 * License: MS-RSL – see LICENSE.md for details 4 */ 5 6/* 7Logger for a CoCalc project 8 9The logger in packages/hub uses this one as well, but with some minor configuration changes. 10 11Use this one throuout the project, since it automatically prefixes all log messages with "cocalc:project:" 12*/ 13 14import { getLogger as getLoggerMain } from "@cocalc/backend/logger"; 15 16const rootLogger = getLoggerMain("project"); 17 18export default function getLogger(name: string) { 19 return rootLogger.extend(name); 20} 21 22export { getLogger }; 23 24