View init.coffee
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->
View Events.php
<?php namespace ProcessWire;
class Events extends PagesType {
/**
* Construct the Events manager for the given parent and template
*
* @param Template|int|string|array $templates Template object or array of template objects, names or IDs
* @param int|Page|array $parents Parent ID or array of parent IDs (may also be Page or array of Page objects)
*/
View stacktrace.java
Cause
com.k15t.scroll.runtime.confluence.content.transform.render.RenderingException: Failed to render template '/page.vm'.
at com.k15t.scroll.viewport.infra.render.VelocityTemplateAdapter.render(VelocityTemplateAdapter.java:33)
caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'template' in class com.k15t.scroll.viewport.api.placeholder.IncludePlaceholder threw exception com.k15t.scroll.runtime.confluence.content.transform.render.RenderingException: Failed to render template '/templates/modules/product/banner.vm'. at templates/modules_template.vm[line 5, column 42]
at org.apache.velocity.runtime.parser.node.ASTMethod.handleInvocationException(ASTMethod.java:337)
caused by: com.k15t.scroll.runtime.confluence.content.transform.render.RenderingException: Failed to render template '/templates/modules/product/banner.vm'.
at com.k15t.scroll.viewport.infra.render.VelocityTemplateAdapter.render(VelocityTemplateAdapter.java:33)
caused by: org.apache.velocity.exceptio
View iframeCSSinject.html
<script>
var Arrive=function(e,t,n){"use strict";function r(e,t,n){l.addMethod(t,n,e.unbindEvent),l.addMethod(t,n,e.unbindEventWithSelectorOrCallback),l.addMethod(t,n,e.unbindEventWithSelectorAndCallback)}function i(e){e.arrive=f.bindEvent,r(f,e,"unbindArrive"),e.leave=d.bindEvent,r(d,e,"unbindLeave")}if(e.MutationObserver&&"undefined"!=typeof HTMLElement){var o=0,l=function(){var t=HTMLElement.prototype.matches||HTMLElement.prototype.webkitMatchesSelector||HTMLElement.prototype.mozMatchesSelector||HTMLElement.prototype.msMatchesSelector;return{matchesSelector:function(e,n){return e instanceof HTMLElement&&t.call(e,n)},addMethod:function(e,t,r){var i=e[t];e[t]=function(){return r.length==arguments.length?r.apply(this,arguments):"function"==typeof i?i.apply(this,arguments):n}},callCallbacks:function(e,t){t&&t.options.onceOnly&&1==t.firedElems.length&&(e=[e[0]]);for(var n,r=0;n=e[r];r++)n&&n.callback&&n.callback.call(n.elem,n.elem);t&&t.options.onceOnly&&1==t.firedElems.length&&t.me.unbindEventWithSelectorAndC
View page.vm
## place somewhere at the bottom before </body> - doesn't matter
<script>
window.spaceKey = '$repository.key'
</script>
View redirect.html
<script>
var versions = [
#foreach ($v in $versions.available)
"$v.name",
#end
]
var x = versions.reverse().reduce(function(acc, item, index, items){
if (acc) {
return acc
View jsonactions.vm
#if( $url.query )
## Only execute when there is a query called action=json. This is our API route more or less.
## For example: localhost:8090/?action=json.getBlogPosts&pages=Test1|||Test2
## This will execute the getBlogPosts Macro with "pages" as parameter
#if( $url.query.indexOf('action=json.') != -1 )
#set( $actionIdentifier = 'action=json.' )
#if( $url.query.indexOf('&') != -1 )
#set( $action = $url.query.substring($actionIdentifier.length(),$url.query.indexOf('&')))
#set( $i = "$actionIdentifier$action" )
#set( $l = $i.length() + 1 )
View .zshrc
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH=~/.oh-my-zsh
# Set name of the theme to load. Optionally, if you set this to "random"
# it'll load a random theme each time that oh-my-zsh is loaded.
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
ZSH_THEME="bureau"
View truthtable.js
// usage : truthTable((a,b)=>a&&b, 2)
// 0,0 - 0
// 0,1 - 0
// 1,0 - 0
// 1,1 - 1
function truthTable(question, argcount) {
var combinations = binaryCombos(argcount)
for (var combination in combinations) {
combination = combinations[combination].reverse()