$/
artifacts/
build/
docs/
lib/
packages/
samples/
src/
tests/
This file contains 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
namespace Testing | |
{ | |
public class NewsController_LatestNews | |
{ | |
[Theory] | |
[AutoData] | |
public void Should_be_news_items_ordered_by_date_descending(IEnumerable<NewsResultItem> newsResultItems) | |
{ | |
var searchContext = Substitute.For<IProviderSearchContext>(); | |
var queryable = new LuceneProviderQueryableStub(enumerable); |
This file contains 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
# This script will set up (and install if needed) Apache Solr for a Sitecore instance. | |
# This does NOT configure Sitecore to use Solr, | |
# just the Solr server and cores for Sitecore to connect to once it is set up to use Solr. | |
# So, what does it do? | |
# | |
# * Installs SOLR, if needed, from the Bitnami SOLR stack: https://bitnami.com/stack/solr/installer | |
# * Creates a SOLR config set for the cores to share (shared schema) | |
# * Creates SOLR cores for all Sitecore indexes, including secondary cores to support online reindexing (Switch on Rebuild) |
This file contains 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
// ------------ | |
// counterStore.js | |
// ------------ | |
import { | |
INCREMENT_COUNTER, | |
DECREMENT_COUNTER | |
} from '../constants/ActionTypes'; | |
const initialState = { counter: 0 }; |
This file contains 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
import React from 'react'; | |
import _ from 'lodash'; | |
import Rx from 'rx'; | |
import superagent from 'superagent'; | |
let api = { | |
host: 'http//localhost:3001', | |
getData(query, cb) { | |
superagent |
This file contains 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
'use 6to5'; | |
const rx = require('rx'); | |
const request = require('request'); | |
let wrapMethodInRx = (method) => { | |
return function(...args) { | |
return rx.Observable.create((subj) => { | |
// Push the callback as the last parameter | |
args.push((err, resp, body) => { |
This file contains 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
import { Component } from "React"; | |
export var Enhance = ComposedComponent => class extends Component { | |
constructor() { | |
this.state = { data: null }; | |
} | |
componentDidMount() { | |
this.setState({ data: 'Hello' }); | |
} | |
render() { |
This file contains 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
var React = require('react'); | |
var events = require('add-event-listener'); | |
var isVisible = require('../isVisible'); | |
var LazyLoad = React.createClass({ | |
displayName: 'LazyLoad', | |
propTypes: { | |
distance: React.PropTypes.number, | |
component: React.PropTypes.node.isRequired, | |
children: React.PropTypes.node.isRequired |
This file contains 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 Sitecore.Mvc.Presentation | |
@using Sitecore.Mvc | |
@model RenderingModel | |
@{ | |
Layout = null; | |
Sitecore.Context.Items["twitter:title"] = Model.Item["title"] | |
Sitecore.Context.Items["twitter:description"] = Model.Item["description"] | |
} | |
<h1>@Html.Sitecore().Field("title")</h1> | |
@Html.Sitecore().Field("text") |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
NewerOlder