Skip to main content

Posts

Showing posts from February, 2019

C# Split the string and preserve the word.

using System.Text.RegularExpressions;        private List<string> SplitPreserveWord(string sentence, int splitLength = 132)         {             string[] words = sentence.Split(' ');             var parts = new List<string>();             string part = string.Empty;             foreach (var word in words)             {                 if (part.Length + GetSpecialCharCount(part) + word.Length + GetSpecialCharCount(word) < splitLength)                 {                     part += string.IsNullOrEmpty(part) ? word : " " + word;                 }                 el...

Angular - Part 1

What is Angular? Angular is a platform that makes it easy to build applications with the web. Angular combines declarative templates, dependency injection, end to end tooling, and integrated best practices to solve development challenges. Angular empowers developers to build applications that live on the web, mobile, or the desktop. Angular lets you extend HTML with HTML attributes called directives. Angular directives offer functionality to HTML applications. Angular is open source front end framework and it was written in Typescript. And it was built by developers of google. Features of Angular. Following are the key features of Angular: Components − The earlier version of Angular had a focus of Controllers but now has changed the focus to having components over controllers. Components help to build the applications into many modules. This helps in better maintaining the application over a period of time. TypeScript − The newer version of Angular is based on Typ...