Bird
0
0

You ran composer create-project laravel/laravel without specifying a folder name. What will happen?

medium📝 Debug Q14 of 15
Laravel - Basics and Architecture
You ran composer create-project laravel/laravel without specifying a folder name. What will happen?
ALaravel installs in the current directory
BComposer throws an error for missing folder name
CLaravel installs in a folder named 'laravel'
DComposer installs Laravel globally
Step-by-Step Solution
Solution:
  1. Step 1: Check default behavior of create-project

    If no folder name is given, Composer uses the package name as the folder.
  2. Step 2: Apply to Laravel package

    Since the package is laravel/laravel, it creates a folder named laravel.
  3. Final Answer:

    Laravel installs in a folder named 'laravel' -> Option C
  4. Quick Check:

    No folder name defaults to package name folder [OK]
Quick Trick: No folder name? Uses package name as folder [OK]
Common Mistakes:
  • Expecting an error for missing folder
  • Thinking it installs in current folder
  • Assuming global installation happens

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Laravel Quizzes