Coder Social home page Coder Social logo

redrocket.utilities.core's Introduction

RedRocket Utilities

The RedRocket Utility project houses many helper methods that are common throughout the framework. The goal of the utility project is to minimize external dependencies and provide common functionality, also allowing the utility framework to be used outside of the RedRocket infrastructure.

Installation

Install via NuGet (Either via manage packages, or Package Manager Console)

Install-Package RedRocket.Utilities.Core

##String Extensions To see a more through usages see the accompanying tests https://github.com/TylerGarlick/RedRocket.Utilities.Core/blob/master/RedRocket.Utilities.Core.Tests/StringExtensionTests.cs

String Formating with .P(object[] args)

The P() extension method is a direct equivelent of string.Format()

string.Format("{0} {1}, "Hello", "World"); 
// Result:  "Hello World"

"{0} {1}".P("Hello", "World");
// Result: "Hello World"

"Total Number of Orders: {0}".P(25);
// Result: "Total Number of Orders: 25"

var someStringWithSomeFormatting = "This is my {0} string";
someStringWithSomeFormatting.P("fawesome");
// Result: "This is my fawesome string"

String Formating with .ToCamelCase(string[] args)

The ToCamelCase() extension method takes a string and a split args, and turns it into a camel cased string.

"hello_world".ToCamelCase("_");
// Result: "HelloWorld"

// You can add as many seperating characters as needed.  Very flexible.
"hello_world  1".ToCamelCase("_", " ");
// Result: "HelloWorld1"

redrocket.utilities.core's People

Watchers

Tyler Garlick avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.