1
0
mirror of https://github.com/mgerb/mywebsite synced 2026-01-13 03:02:49 +00:00

updated bunch of file paths and changed the way posts are loaded

This commit is contained in:
2016-01-05 12:28:04 -06:00
parent 4bb8cae81e
commit 6ab45fe935
13249 changed files with 317868 additions and 2101398 deletions

53
node_modules/swig/lib/loaders/index.js generated vendored Normal file
View File

@@ -0,0 +1,53 @@
/**
* @namespace TemplateLoader
* @description Swig is able to accept custom template loaders written by you, so that your templates can come from your favorite storage medium without needing to be part of the core library.
* A template loader consists of two methods: <var>resolve</var> and <var>load</var>. Each method is used internally by Swig to find and load the source of the template before attempting to parse and compile it.
* @example
* // A theoretical memcached loader
* var path = require('path'),
* Memcached = require('memcached');
* function memcachedLoader(locations, options) {
* var memcached = new Memcached(locations, options);
* return {
* resolve: function (to, from) {
* return path.resolve(from, to);
* },
* load: function (identifier, cb) {
* memcached.get(identifier, function (err, data) {
* // if (!data) { load from filesystem; }
* cb(err, data);
* });
* }
* };
* };
* // Tell swig about the loader:
* swig.setDefaults({ loader: memcachedLoader(['192.168.0.2']) });
*/
/**
* @function
* @name resolve
* @memberof TemplateLoader
* @description
* Resolves <var>to</var> to an absolute path or unique identifier. This is used for building correct, normalized, and absolute paths to a given template.
* @param {string} to Non-absolute identifier or pathname to a file.
* @param {string} [from] If given, should attempt to find the <var>to</var> path in relation to this given, known path.
* @return {string}
*/
/**
* @function
* @name load
* @memberof TemplateLoader
* @description
* Loads a single template. Given a unique <var>identifier</var> found by the <var>resolve</var> method this should return the given template.
* @param {string} identifier Unique identifier of a template (possibly an absolute path).
* @param {function} [cb] Asynchronous callback function. If not provided, this method should run synchronously.
* @return {string} Template source string.
*/
/**
* @private
*/
exports.fs = require('./filesystem');
exports.memory = require('./memory');