1 import boxen from "boxen"
2
3 const defaultConfig = {
4 padding: 1,
5 borderColor: `blue`,
6 borderStyle: `double`,
7 }
8
9 const defaultMessage =
10 `Medusa collects anonymous usage analytics\n` +
11 `to help improve Medusa for all users.\n` +
12 `\n` +
13 `If you'd like to opt-out, you can use \`medusa telemetry --disable\`\n`
14
15 /**
16 * Analytics notice for the end-user
17 */
18 function showAnalyticsNotification(
19 config = defaultConfig,
20 message = defaultMessage
21 ) {
22 console.log(boxen(message, config))
23 }
24
25 export default showAnalyticsNotification