This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
expect({ | |
name: 'Tiger', | |
species: 'Felis Catus', | |
favouriteSnack: 'Tuna', | |
schedule: { | |
breakfast: '08:00', | |
naptime: '10:00', | |
dinner: '12:00', | |
tea: '18:00' | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe('housecat comparison', () => { | |
it('should let me know that both objects are the same', () => { | |
expect({ | |
name: 'Tiger', | |
species: 'Felis Catus', | |
favouriteSnack: 'Tuna', | |
schedule: { | |
breakfast: '08:00', | |
naptime: '10:00', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Helper method enumerates over and returns lines in a file | |
static IEnumerable<string> ReadFrom(string file) | |
{ | |
string line; | |
using(var reader = System.IO.File.OpenText(file)) | |
{ | |
while((line = reader.ReadLine()) != null) | |
{ | |
yield return line; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 --> | |
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> | |
<appSettings> | |
<add key="umbracoConfigurationStatus" value="" xdt:Transform="SetAttributes" xdt:Locator="Match(key)"/> | |
</appSettings> | |
</configuration> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 --> | |
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform"> | |
<!-- | |
Set your connection string in the XML snippet below | |
--> | |
<connectionStrings> | |
<add name="umbracoDbDSN" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@inherits Umbraco.Web.Mvc.UmbracoTemplatePage | |
@{ | |
Layout = null; | |
umbraco.library.ChangeContentType("text/plain"); | |
} | |
@(Model.Content.GetPropertyValue<string>("fileContent")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<add name="robots-rewrite" | |
virtualUrl="^~/robots.txt" | |
destinationUrl="~/robotstxt" | |
/> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@inherits Umbraco.Web.Mvc.UmbracoTemplatePage | |
@{ | |
Layout = null; | |
umbraco.library.ChangeContentType("text/xml"); | |
} | |
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> | |
@foreach (var root in Umbraco.TypedContentAtRoot()) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using MyProject.Models; | |
using Umbraco.Web; | |
using Our.Umbraco.Ditto; | |
namespace MyProject.Services | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
builder.RegisterInstance(umbracoHelper.ContentQuery).As<ITypedPublishedContentQuery>(); | |
builder.RegisterType<ResourceService>().As<IResourceService>(); |