This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Joe Armstrong: | |
面向对象语言的问题是,它们永远都要随身携带那些隐式的环境。 | |
你只需要一个香蕉,但却得到一个拿着香蕉的大猩猩...以及整个丛林 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.IOException; | |
import java.net.InetSocketAddress; | |
import com.sun.net.httpserver.HttpServer; | |
public class HttpServerSample { | |
public static void main(String[] args) throws IOException { | |
HttpServer server = HttpServer.create(new InetSocketAddress(8080), 0); | |
server.createContext("/", exchange -> { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { View, Text, FlatList, TouchableOpacity, ListRenderItem } from "react-native"; | |
import React, { Component } from "react"; | |
import { map } from "lodash"; | |
import { ViewPager } from "rn-viewpager"; | |
interface Page<T> { | |
keyExtractor?: (item: T) => any; | |
data?: T[]; | |
renderItem?: ListRenderItem<T>; | |
renderPage?: (prePage, nextPage) => JSX.Element; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"master_password" : "ChangedThis01" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import JSONPropertyBinding from "sap/ui/model/json/JSONPropertyBinding"; | |
import JSONModel from "sap/ui/model/json/JSONModel"; | |
import { forEach, isEqual } from "lodash"; | |
/** | |
* overwrite set property logic | |
*/ | |
JSONModel.prototype.setProperty = function(sPath, oValue, oContext, bAsyncUpdate) { | |
var sResolvedPath = this.resolve(sPath, oContext), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Control from "sap/ui/core/Control"; | |
import echarts from "echarts"; | |
import RenderManager from "sap/ui/core/RenderManager"; | |
const E_CHARTS = "e_chart"; | |
export default class EChartsControl extends Control { | |
metadata = { | |
properties: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Monaco Demo</title> | |
<script src="https://cdn.bootcss.com/require.js/2.3.6/require.min.js"></script> | |
</head> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
go get -u -v golang.org/x/tools/cmd/gopls | |
go get -u -v github.com/ramya-rao-a/go-outline | |
go get -u -v github.com/acroca/go-symbols | |
go get -u -v github.com/mdempsky/gocode | |
go get -u -v github.com/rogpeppe/godef | |
go get -u -v golang.org/x/tools/cmd/godoc | |
go get -u -v github.com/zmb3/gogetdoc | |
go get -u -v golang.org/x/lint/golint | |
go get -u -v github.com/fatih/gomodifytags |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add additonal d.ts files to the JavaScript language service and change. | |
// Also change the default compilation options. | |
// The sample below shows how a class Facts is declared and introduced | |
// to the system and how the compiler is told to use ES6 (target=2). | |
// validation settings | |
monaco.languages.typescript.javascriptDefaults.setDiagnosticsOptions({ | |
noSemanticValidation: true, | |
noSyntaxValidation: false | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Word.run((ctx) => { | |
Office.context.document.addHandlerAsync(Office.EventType.DocumentSelectionChanged, (e) => { | |
console.log(e) | |
}) | |
return ctx.sync() | |
}) | |
OlderNewer