https://www.exakat.io/en/6-good-practices-for-use/
"Any call to a fully namespaced should be avoided, and at least aliased. Firstly, this shorten the code, keep it easier to read. This may also be called ‘Avoid long classes name in code’.
..........
.............
....."
But in some cases, I consider it something a little excessive.
For example
--- SCRIPT ---
<?php
use MyClass as MyClass; // little excessive?
// ...
--- END SCRIPT ---
What do you think?
https://www.exakat.io/en/6-good-practices-for-use/
"Any call to a fully namespaced should be avoided, and at least aliased. Firstly, this shorten the code, keep it easier to read. This may also be called ‘Avoid long classes name in code’.
..........
.............
....."
But in some cases, I consider it something a little excessive.
For example
--- SCRIPT ---
<?php
use MyClass as MyClass; // little excessive?
// ...
--- END SCRIPT ---
What do you think?
This makes no sense at all. You don't need an alias if you use the class
at it is:
<?php
use MyClass;
Hey guy. Would You want to get rich with me doing programming? If yes, call me !!!!!!!!!
✆☎☏📱📞 : [0-9]{3} [0-9]{8}
Flash kirjutas Pühapäev, 3. juuli 2022 kl 10:23:18 UTC+2:
https://www.exakat.io/en/6-good-practices-for-use/
"Any call to a fully namespaced should be avoided, and at least aliased.
Firstly, this shorten the code, keep it easier to read. This may also be
called ‘Avoid long classes name in code’.
..........
.............
....."
But in some cases, I consider it something a little excessive.
For example
--- SCRIPT ---
<?php
use MyClass as MyClass; // little excessive?
// ...
--- END SCRIPT ---
What do you think?
Il 06/07/22 20:02, Arno Welzel ha scritto:
This makes no sense at all. You don't need an alias if you use the class
at it is:
<?php
use MyClass;
~$ php -r 'use stdClass;'
Warning: The use statement with non-compound name 'stdClass' has no
effect in Command line code on line 1
https://www.exakat.io/en/6-good-practices-for-use/
"Any call to a fully namespaced should be avoided, and at least aliased. Firstly, this shorten the code, keep it easier to read. This may also be called ‘Avoid long classes name in code’.
..........
.............
....."
But in some cases, I consider it something a little excessive.
For example
--- SCRIPT ---
<?php
use MyClass as MyClass; // little excessive?
// ...
--- END SCRIPT ---
What do you think?
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 349 |
Nodes: | 16 (2 / 14) |
Uptime: | 120:57:19 |
Calls: | 7,612 |
Files: | 12,789 |
Messages: | 5,684,239 |