Smart stores for Riot (like flux, based on ideas from RiotControl)
Small (<1.5Kb) flux-like store container.
Make sure loot.js is included in your page after riot.js:
-- clean up database from previous test | |
DROP SCHEMA public CASCADE; | |
CREATE SCHEMA public; | |
-- create EAV tables | |
CREATE TABLE entity ( | |
id SERIAL PRIMARY KEY, | |
name TEXT, | |
description TEXT | |
); |
[Serializable] | |
public class Blobbed<T> : IUserType where T : class | |
{ | |
public new bool Equals(object x, object y) | |
{ | |
if (x == null && y == null) | |
return true; | |
if (x == null || y == null) | |
return false; |
<template> | |
<div> | |
<h1> {{ message }} </h1> | |
<div | |
</template> | |
<script> | |
export default { | |
/* Child component registration */ | |
components: {}, | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using DocumentFormat.OpenXml.Packaging; | |
using DocumentFormat.OpenXml.Wordprocessing; | |
using iTextSharp; | |
using iTextSharp.text.pdf; | |
using System.IO; |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Offline</title> | |
</head> | |
<body style="margin:3em;font-family:sans-serif"> | |
<h2>Offline</h2> | |
<p>This site is offline for maintenance.</p> | |
<!-- |
#region ICriteria async API | |
// Usage ICriteria.ListAsync<T>() | |
var customers = await session.CreateCriteria<Customer>().ListAsync<Customer>(); | |
// Usage ICriteria.UniqueResultAsync<T>() | |
var customer = await session | |
.CreateCriteria<Customer>() | |
.Add(Restrictions.Eq("Name", "Erdtsieck")) | |
.UniqueResultAsync<Customer>(); |
<Project | |
xmlns="http://schemas.microsoft.com/developer/msbuild/2003" | |
ToolsVersion="4.0" | |
DefaultTargets="Demo" > | |
<Target Name="Demo"> | |
<PropertyGroup> | |
<CurrentDate>$([System.DateTime]::Now.ToString(yyyyMMdd-mmss))</CurrentDate> | |
</PropertyGroup> |
I've been deceiving you all. I had you believe that Svelte was a UI framework — unlike React and Vue etc, because it shifts work out of the client and into the compiler, but a framework nonetheless.
But that's not exactly accurate. In my defense, I didn't realise it myself until very recently. But with Svelte 3 around the corner, it's time to come clean about what Svelte really is.
Svelte is a language.
Specifically, Svelte is an attempt to answer a question that many people have asked, and a few have answered: what would it look like if we had a language for describing reactive user interfaces?
A few projects that have answered this question: