None
- /reference/svn/functions/svn-fs-txn-root.xml
- /reference/svn/functions/svn-repos-fs-commit-txn.xml
- /reference/svn/functions/svn-fs-file-contents.xml
- /reference/svn/functions/svn-fs-make-file.xml
| <?php | |
| /** | |
| * Thinking through a possible implementation for wrapping native WordPress hooks with my own. | |
| */ | |
| declare( strict_types=1 ); | |
| namespace JMichaelWard\PluginConcept; | |
| /** |
So you want to write a sync system for a web app with offline and realtime support? Good luck. You might find the following resources useful.
Database in a browser, a spec (Stepan Parunashvili)
What problem are we trying to solve with a sync system?
The web of tomorrow (Nikita Prokopov)
[EDIT: I've added a part 2 to this blog post, to address some of the feedback that has come up: https://gist.github.com/getify/706e5e10822a298375da40f9cc1fa295]
Recently, this article on "The JavaScript Block Statement" came out, and it received some good discussion in a reddit thread. But the general reaction seems to be against this approach. That saddens me.
| <?php | |
| /** | |
| * Charcoal Valet Driver | |
| * | |
| * Supported Valet Version: 4 | |
| */ | |
| namespace Valet\Drivers\Custom; |
| ./linelen_hist.sh src '*.c' | |
| COLS COUNT | |
| 2 1317 βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ | |
| 4 583 βββββββββββββββββββββββββββ | |
| 6 500 βββββββββββββββββββββββ | |
| 8 253 ββββββββββββ | |
| 10 264 βββββββββββββ | |
| 12 448 βββββββββββββββββββββ | |
| 14 417 ββββββββββββββββββββ | |
| 16 476 ββββββββββββββββββββββ |
| /* Ultra lightweight Github REST Client */ | |
| // original inspiration via https://gist.github.com/v1vendi/75d5e5dad7a2d1ef3fcb48234e4528cb | |
| const token = 'github-token-here' | |
| const githubClient = generateAPI('https://api.github.com', { | |
| headers: { | |
| 'User-Agent': 'xyz', | |
| 'Authorization': `bearer ${token}` | |
| } | |
| }) |
| const terser = require("terser"); | |
| const sass = require("sass"); | |
| module.exports = (eleventyConfig) => { | |
| // Compile Sass | |
| eleventyConfig.addTemplateFormats("scss"); | |
| eleventyConfig.addExtension("scss", { | |
| outputFileExtension: "css", | |
| compile: function (contents, inputPath) { |
In this simple example we create a function for obtaining data from an external source and caching it for 24 hours. You can use the function hd_get_external_data() to get the data and work with it in your site.
If you want to force a refresh of the cache, you can pass a value of true into the function.
You can place the code into your themes functions.php file or better still in a plugin. If you are placing it in a plugin, remember to use function_exists() when using this. This ensures that the code will fail correctly if the plugin is not active.
| // ==UserScript== | |
| // @name Prevent link mangling on Google | |
| // @namespace LordBusiness.LMG | |
| // @match https://www.google.com/search | |
| // @grant none | |
| // @version 1.1 | |
| // @author radiantly | |
| // @description Prevent google from mangling the link when copying or clicking the link on Firefox | |
| // ==/UserScript== |