@lucidlayer/traceform-onboard
Version:
Interactive CLI tool and onboarding wizard for setting up, validating, and configuring Traceform in React projects. Automates project setup, developer onboarding, and toolchain validation for React, TypeScript, and monorepos.
28 lines (27 loc) • 1.24 kB
JavaScript
// SPDX-License-Identifier: Apache-2.0
import chalk from 'chalk';
import inquirer from 'inquirer';
// Note: Programmatically checking browser extension installation is not feasible.
// We will guide the user through the manual installation process.
export async function checkBrowserExtension() {
console.log(chalk.yellow('\nNext step: Install the Traceform browser extension manually.'));
console.log(chalk.cyan('Download Link: ' + 'https://github.com/lucidlayer/traceform' + '/releases'));
// TODO: Add link to detailed setup guide in README or docs
console.log(chalk.cyan(' Detailed Guide: <Link to README/Docs section>'));
console.log(''); // Add spacing
const { confirmed } = await inquirer.prompt([
{
type: 'confirm',
name: 'confirmed',
message: 'Have you installed and enabled the Traceform Browser extension?',
default: false, // Default to no, requiring explicit confirmation
},
]);
if (confirmed) {
console.log(chalk.green(' Browser Extension step confirmed.'));
}
else {
console.log(chalk.yellow(' Please install/enable the Browser extension and run the check again.'));
}
return confirmed;
}