Legend:
- βοΈ method changes
this. - π method does not change
this.
Array<T>.prototype.*:
concat(...items: Array: T[]π ES3
| function isElementInViewport(el) { | |
| let rect = el.getBoundingClientRect(); | |
| return ( | |
| rect.top >= 0 && | |
| rect.left >= 0 && | |
| rect.bottom <= (window.innerHeight || document.documentElement.clientHeight) && | |
| rect.right <= (window.innerWidth || document.documentElement.clientWidth) | |
| ); | |
| } |
| import path from "path" | |
| import webpack from "webpack" | |
| import ExtractTextPlugin from "extract-text-webpack-plugin" | |
| import pkg from "./package.json" | |
| // note that this webpack file is exporting a "makeConfig" function | |
| // which is used for phenomic to build dynamic configuration based on your needs | |
| // see the end of the file if you want to export a default config |
| show_branch() { | |
| echo $(git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ \1/') | |
| } | |
| update_pr() { | |
| CURRENT_BRANCH=$(show_branch) | |
| IFS='/' read -ra array <<< "$CURRENT_BRANCH" | |
| PR_ID=${array[1]} | |
| if [ "${array[0]}" != "pr" ] |
| // Future versions of Hyper may add additional config options, | |
| // which will not automatically be merged into this file. | |
| // See https://hyper.is#cfg for all currently supported options. | |
| module.exports = { | |
| config: { | |
| paneNavigation: { | |
| indicatorPrefix: 'β₯', | |
| hotkeys: { | |
| navigation: { |
| import { Directive, Input, TemplateRef, ViewContainerRef, OnInit } from '@angular/core'; | |
| export class NgLetContext { | |
| $implicit: any = null; | |
| ngLet: any = null; | |
| } | |
| @Directive({ | |
| selector: '[ngLet]' | |
| }) |
| class Operation(): | |
| def __init__(self, input_nodes=None): | |
| self.input_nodes = input_nodes | |
| self.output = None | |
| # Append operation to the list of operations of the default graph | |
| _default_graph.operations.append(self) | |
| def forward(self): | |
| pass |
| class add(BinaryOperation): | |
| """ | |
| Computes a + b, element-wise | |
| """ | |
| def forward(self, a, b): | |
| return a + b | |
| def backward(self, upstream_grad): | |
| raise NotImplementedError |
| class Graph(): | |
| def __init__(self): | |
| self.operations = [] | |
| self.placeholders = [] | |
| self.variables = [] | |
| self.constants = [] | |
| def as_default(self): | |
| global _default_graph | |
| _default_graph = self |
| class Constant(): | |
| def __init__(self, value=None): | |
| self.__value = value | |
| _default_graph.constants.append(self) | |
| @property | |
| def value(self): | |
| return self.__value | |
| @value.setter |