Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Modern Web Development
with
Laravel | Composer NPM
Webpack
Who am I?
What is it?
• Vendor Dependency Management
• PHP Code Autoloader
• Security Management
• Extra Script
• Development Enviro...
It is a backend
development work flow
Why Vendor Dependency Management ?
Keep Organize
้้ชใ ่มไารเา ้ถresopmocาลวเานะจ3 rd-party อ ืรหlibrary ้้ชใามน ักาท
รไงา ...
Why Vendor Dependency Management ?
Prevent direct edit on 3rd-party code
การแก้ไข code ของ vendor โดยตรง ส่งผลให้ เพิ่มภาร...
Why Vendor Dependency Management ?
Security
ทันที้ที่้library มีการเปลี่ยนแปลง้สามารถ้update library ได้้ทันที้แ่่้run
`Co...
Vendor Dependency Management
• How’s it work?
Composer.json, composer.lock, vendor folder
Vendor Dependency Management
• Difference between `composer install` and `composer update`
`composer install` is not only ...
Working with GIT
• Commit composer.lock is a MUST
• Same branch multi-developers
• Switching branch
• composer.lock merge ...
Working with GIT
composer.lock merge conflict https://blog.martinhujer.cz/17-tips-for-
using-composer-efficiently/
PHP Code Autoloader
• composer install --optimize-autoloader
Index.php
Security Management
• `composer outdated`
Analyze composer.lock
Security Management
• OWASP_Dependency_Check https://www.owas
p.org/index.php/OWASP_Dependency_Check
Analyze composer.lock
Security Management
• SensioLabs Security Checker
https://github.com/sensiolabs/security-checker
Analyze composer.lock
Extra Script
• Laravel auto discovery
composer.json
Extra Script
• Laravel extra script
composer.json
Extra Script
• BrainMaestro/composer-git-hooks - automate GIT Hook to
automate `composer install`
https://github.com/Brain...
Development Environment
• Required PHP and php-extension
Development Environment
• Multi-platform PHP development
Development Environment
• Patch vendor package while waiting vendor release new PR
Q & A
รับสมั่ร Laravel Developer
ทั้ง Full time และ Part time
ไม่จำกัดจำนวน
ติดต่อ Pairote@netway.co.th
This Photo by Unknown au...
Modern web development part 2   composer
Modern web development part 2   composer
Upcoming SlideShare
Loading in …5
×

Modern web development part 2 composer

41 views

Published on

This is presented by Pairote Rojanaphusit, CEO, Netway Communication at Laravel Meet Up, the 1st Laravel Gathering in Thailand. Please visit www.rvsitebuilder.com or www.dev.rvsitebuilder.com for more info.

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Modern web development part 2 composer

  1. 1. Modern Web Development with Laravel | Composer NPM Webpack
  2. 2. Who am I?
  3. 3. What is it? • Vendor Dependency Management • PHP Code Autoloader • Security Management • Extra Script • Development Environment
  4. 4. It is a backend development work flow
  5. 5. Why Vendor Dependency Management ? Keep Organize ้้ชใ ่มไารเา ้ถresopmocาลวเานะจ3 rd-party อ ืรหlibrary ้้ชใามน ักาท รไงา ่ยอ
  6. 6. Why Vendor Dependency Management ? Prevent direct edit on 3rd-party code การแก้ไข code ของ vendor โดยตรง ส่งผลให้ เพิ่มภาระใน การ manage และ update vendor code ต้องทาการ merge code ให้ดี สมัยก่อนจาเป็นต้องทาแบบนี้เพราะ PHP OOP ยังไม่ดีไม่มี Namespace, Autoload การแก้ไข
  7. 7. Why Vendor Dependency Management ? Security ทันที้ที่้library มีการเปลี่ยนแปลง้สามารถ้update library ได้้ทันที้แ่่้run `Composer update`
  8. 8. Vendor Dependency Management • How’s it work? Composer.json, composer.lock, vendor folder
  9. 9. Vendor Dependency Management • Difference between `composer install` and `composer update` `composer install` is not only new install but It means install or update whatever listed on composer.lock. `composer update` will check if any new version and try to update it. It always change composer.lock to new state even if no change on composer.json
  10. 10. Working with GIT • Commit composer.lock is a MUST • Same branch multi-developers • Switching branch • composer.lock merge conflict
  11. 11. Working with GIT composer.lock merge conflict https://blog.martinhujer.cz/17-tips-for- using-composer-efficiently/
  12. 12. PHP Code Autoloader • composer install --optimize-autoloader Index.php
  13. 13. Security Management • `composer outdated` Analyze composer.lock
  14. 14. Security Management • OWASP_Dependency_Check https://www.owas p.org/index.php/OWASP_Dependency_Check Analyze composer.lock
  15. 15. Security Management • SensioLabs Security Checker https://github.com/sensiolabs/security-checker Analyze composer.lock
  16. 16. Extra Script • Laravel auto discovery composer.json
  17. 17. Extra Script • Laravel extra script composer.json
  18. 18. Extra Script • BrainMaestro/composer-git-hooks - automate GIT Hook to automate `composer install` https://github.com/BrainMaestro/composer-git-hooks
  19. 19. Development Environment • Required PHP and php-extension
  20. 20. Development Environment • Multi-platform PHP development
  21. 21. Development Environment • Patch vendor package while waiting vendor release new PR
  22. 22. Q & A
  23. 23. รับสมั่ร Laravel Developer ทั้ง Full time และ Part time ไม่จำกัดจำนวน ติดต่อ Pairote@netway.co.th This Photo by Unknown author is licensed under CC BY.

×