Se ha denunciado esta presentación.
Se está descargando tu SlideShare. ×

Craate Your Own PHP Package - DILo Surabaya

Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Anuncio
Próximo SlideShare
Introduction to Vim 8.0
Introduction to Vim 8.0
Cargando en…3
×

Eche un vistazo a continuación

1 de 28 Anuncio

Más Contenido Relacionado

Presentaciones para usted (20)

Similares a Craate Your Own PHP Package - DILo Surabaya (20)

Anuncio

Más reciente (20)

Anuncio

Craate Your Own PHP Package - DILo Surabaya

  1. 1. Create Your Own PHP Package antoniputra.com
  2. 2. Antoni - Web Developer Github: github.com/antoniputra Twitter: @antoni_putra12 Telegram: t.me/antoniputra Freelancer & SurabayaDev Organizer
  3. 3. ● Like the Fanspage: https://www.facebook.com/sura bayadev ● Join Telegram Group: https://t.me/surabayadev ● Follow github: https://github.com/surabayadev ● Follow Instagram: https://www.instagram.com/sur abayadev Join SurabayaDev Community
  4. 4. Good Job! Thanks for your support.
  5. 5. Apa itu Package?
  6. 6. Yang kita (programmer) pikirkan Yang orang lain pikirkan
  7. 7. Package adalah bagian dari kode `reusable` yang dapat dimasukan ke aplikasi dan digunakan tanpa harus mengutak-atik fungsionalitas kode didalamnya.
  8. 8. Kadang-kadang didalam Package terdapat Package juga. hal ini disebut: Dependency
  9. 9. Composer Dependency Manager for PHP (seperti Ruby Gems, NPM, etc)
  10. 10. Story Time
  11. 11. Battle of Library Management 1. Googling any packages 2. Download It 3. Extract It 4. Need Update? Repeat (huff) 1. List any packages in your composer.json 2. Run `composer install` in cli 3. Need update? Just run: `composer update` Composer Manual Jaman Now Jaman Byen
  12. 12. Thankyou :’-( SourceForge PHP Classes Google Code All of website that host PHP library
  13. 13. Hi, Composer & Packagist
  14. 14. semver.org Semantic versioning to manage version numbers
  15. 15. 3.9.2 [3 Major] . [9 Minor] . [2 Patch]
  16. 16. Consume Packages in Composer
  17. 17. What is ~ and ^?
  18. 18. (^) Caret ● ^4.1.3 (most used) means >=4.1.3 < 5.0.0 ● ^4.1 means >=4.1.0 < 5.0.0 ● ^0.4 means >=0.4.0 < 0.5.0 ● ^4 means >=4.0.0 < 5.0.0 which is the same as ~4 and 4.*. (~) Tilde ● ~4.1.3 means >=4.1.3 < 4.2.0 ● ~4.1 means >=4.1.0 < 5.0.0 (most used), ● ~0.4 means >=0.4.0 < 1.0.0 ● ~4 means >=4.0.0 < 5.0.0. Tilde and Caret is just Next Significant Release Operators
  19. 19. Create Your Own Package Is it difficult?
  20. 20. Kuat dilakoni lek ra kuat ditinggal ngopi Tetep ngoding senajan ngoding iku angel.
  21. 21. Before you go? ● Do you understand GIT? ● Have you familiar with PSR-2 Coding Standard? ● Have you familiar with PSR-4 Autoloader? ● Have you read Composer Documentation? ● Have you read semver.org?
  22. 22. Or if u need boilerplate? https://github.com/thephpleague/skeleton You can start Package Development from scratch
  23. 23. Create a useful package http://phppackagechecklist.com and follow Package Development best practice here:
  24. 24. then Community will cheers to you
  25. 25. Stupid simple study case: https://github.com/antoniputra/ngeblog
  26. 26. Kesimpulan ● Programmer Jaman now harus bisa nge-GIT ● Selalu gunakan PSR-2 Coding Standard & PSR-4 Autoloader ● Anda dapat memulai package development dengan boilerplate ini https://github.com/thephpleague/skeleton ● Pastikan package yg kalian buat sesuai dengan panduan disini: http://phppackagechecklist.com ● Be Confident. Done is better than perfect.
  27. 27. Jadi kapan kalian akan release Package? This image cannot currently be displayed. Saya tunggu :-*
  28. 28. Terimakasih :-*

×