@mulanjs/mulanjs 1.0.1-dev.20260220133204 → 1.0.1-dev.20260220134357

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/cli/index.js +20 -9
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mulanjs/mulanjs",
3
- "version": "1.0.1-dev.20260220133204",
3
+ "version": "1.0.1-dev.20260220134357",
4
4
  "description": "A powerful, secure, and enterprise-grade JavaScript framework.",
5
5
  "main": "dist/mulan.js",
6
6
  "module": "dist/mulan.esm.js",
package/src/cli/index.js CHANGED
@@ -46,14 +46,20 @@ const LOGO_SVG = `<svg width="50" height="50" viewBox="0 0 120 120" fill="none"
46
46
  <circle cx="75" cy="75" r="2" fill="#FF9800"/>
47
47
  </svg>`;
48
48
 
49
- function printBanner() {
50
- const BANNER_PARTS = [
51
- 'MulanJS',
52
- 'THE WORLD\'S MOST POWERFUL ASTR-Q FRAMEWORK'
49
+ const delay = ms => new Promise(res => setTimeout(res, ms));
50
+
51
+ async function printBanner() {
52
+ const lines = [
53
+ '\x1b[35mMULANJS\x1b[0m',
54
+ '\x1b[33m⚡ THE WORLD\'S MOST POWERFUL ASTR-Q FRAMEWORK ⚡\x1b[0m',
55
+ '\x1b[36mIron Fortress Security: ACTIVE\x1b[0m',
56
+ '-'.repeat(50)
53
57
  ];
54
- console.log('\x1b[35m%s\x1b[0m', BANNER_PARTS[0]);
55
- console.log('\x1b[33m%s\x1b[0m', BANNER_PARTS[1]);
56
- console.log('-'.repeat(50));
58
+
59
+ for (const line of lines) {
60
+ console.log(line);
61
+ await delay(100);
62
+ }
57
63
  }
58
64
 
59
65
  function askQuestion(query) {
@@ -73,7 +79,7 @@ program
73
79
  .option('--ts', 'Initialize as TypeScript project')
74
80
  .option('--js', 'Initialize as JavaScript project')
75
81
  .action(async (projectName, options) => {
76
- printBanner();
82
+ await printBanner();
77
83
  console.log(`\n🚀 Unleashing MulanJS Power: Preparing ${projectName}...\n`);
78
84
 
79
85
  const projectPath = path.resolve(process.cwd(), projectName);
@@ -526,6 +532,7 @@ program
526
532
  .command('dev [args...]')
527
533
  .description('Start the Mulan Development Server')
528
534
  .action(async () => {
535
+ await printBanner();
529
536
  try {
530
537
  const port = await findAvailablePort(1016);
531
538
  console.log(`🚀 Starting Mulan Power Server on port ${port}...`);
@@ -544,7 +551,8 @@ program
544
551
  program
545
552
  .command('build [args...]')
546
553
  .description('Build for production')
547
- .action(() => {
554
+ .action(async () => {
555
+ await printBanner();
548
556
  try {
549
557
  shell('npx webpack --mode production');
550
558
  } catch (e) {
@@ -557,6 +565,7 @@ program
557
565
  .alias('g')
558
566
  .description('Generate a new MulanJS resource')
559
567
  .action(async (type, name) => {
568
+ await printBanner();
560
569
  if (type === 'component') {
561
570
  const compName = name.charAt(0).toUpperCase() + name.slice(1);
562
571
  console.log(`⚡ Generating Component: ${compName}...`);
@@ -589,6 +598,7 @@ program
589
598
  .command('install-extension')
590
599
  .description('Install the MulanJS VS Code Extension for icons and syntax highlighting')
591
600
  .action(async () => {
601
+ await printBanner();
592
602
  console.log('📦 Locating MulanJS VS Code Extension...');
593
603
  try {
594
604
  // Find where mulanjs is installed. If run via npx, __dirname is the cli folder.
@@ -614,6 +624,7 @@ program
614
624
  .command('static')
615
625
  .description('Generate static HTML (SSG) for SEO and performance')
616
626
  .action(async () => {
627
+ await printBanner();
617
628
  const { generateStaticSite } = require('./static-generator');
618
629
  await generateStaticSite();
619
630
  });