之前的文章介紹了 Schematics,現在就來自己建立一個 Schematics collection,我們希望建立出來的 collection 可以保留原有 Angular CLI 的功能,並擴充自己想要的樣板

閱讀全文 »

目前的管理程式碼,大致上可以分成兩種方式, mono 與 multiple repositories,通常是採 Multiple Repo,每一個系統都有自己的 repository 做版控,各自管理自己的套件版本,這聽起來很合理,但目前比較大型的軟體公司,像是 Google 、Facebook、Twitter 等。都是採取 mono repo 的開發模式(請留意上述公司都有自己一套的開發流程)

※沒有哪一種方法好,哪一種方法不好。都有各自的優缺點 !

閱讀全文 »

什麼是 rendertron ? rendertron 是 Google Chrome 團隊推出的另外一個新工具,這工具可以讓 PWA 網站遇到網路爬蟲或是分享到 twitter/Facebook 時,可以產出靜態頁面的效果。換句算說,這工具可以讓我們不用額外處理 Service Side Rendering 卻可以得到相同的效果 (僅局限於網路爬蟲或是 Rich Content Sharing時)。

閱讀全文 »

Angular Material 團隊在前一陣子推出 Angular CDK 的套件,什麼是 Angular CDK ? 簡單的說就是 Angular material 2 底層在使用的功能而樣式的部分就留給我們自己設計。

The goal of the CDK is to give developers more tools to build awesome components for the web. This will be especially useful for projects that want to take advantage of the features of Angular Material without adopting the Material Design visual language. — Angular Team

閱讀全文 »

一般提起 Angular 的 Lazy Loading 時,第一個反應都是透過網址的方式來實作,但是否有方法可以借用 RouterModule 的幫助來產生 chunk 檔案,然後手動作載入的動作呢? 答案是可以的

閱讀全文 »

Angular CLI 1.4 版以後,樣板的產生器就改使用 @angular-devkit/schematics ,而在 10 月初,Nrwl.io 也推出 nx 版的 schematics 樣版集合,所以什麼是 schematics ,我們可以利用他來做什麼樣的事情呢?

閱讀全文 »

.NET Core 所提供的 Angular SPA 範本,用起來都覺得卡卡的,所以只好自己來整一個給 Angular 所使用的架構,跟著以下的步驟,就可以整理出我覺得還滿意的 .NET MVC Core 的程式架構

閱讀全文 »

整合測試主要的目的,是要測試 Component 的 template 的動作是否能如我們所預期的方式運作,而這是單元測試無法涵的範圍

Angular 也貼心準備小幫手,TestBed,來協助我們完成整合測試

閱讀全文 »
0%