1
0
Fork 0

Merge pull request #8469 from abdounikarim/master

Update 01-basic-usage.md - add dump-autoload
pull/8475/head
Jordi Boggiano 2019-12-07 20:41:03 +01:00 committed by GitHub
commit 0d173b6e20
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 2 deletions

View File

@ -241,8 +241,14 @@ be in your project root, on the same level as `vendor` directory is. An example
filename would be `src/Foo.php` containing an `Acme\Foo` class. filename would be `src/Foo.php` containing an `Acme\Foo` class.
After adding the [`autoload`](04-schema.md#autoload) field, you have to re-run After adding the [`autoload`](04-schema.md#autoload) field, you have to re-run
[`dump-autoload`](03-cli.md#dump-autoload) to re-generate the this command :
`vendor/autoload.php` file.
```sh
php composer.phar dump-autoload
```
This command will re-generate the `vendor/autoload.php` file.
See the [`dump-autoload`](03-cli.md#dump-autoload) section for more informations.
Including that file will also return the autoloader instance, so you can store Including that file will also return the autoloader instance, so you can store
the return value of the include call in a variable and add more namespaces. the return value of the include call in a variable and add more namespaces.