Skip to content

Instantly share code, notes, and snippets.

// cf. https://eslint.org/docs/user-guide/configuring
module.exports = {
extends: [
'@my-app/eslint-config', // cf. https://gist.github.com/jhlee8804/f6556886a251221d4d350a07b2327f9d
'plugin:vue/essential', // cf. https://eslint.vuejs.org/rules/#priority-a-essential-error-prevention
'@vue/eslint-config-prettier', // cf. https://github.com/vuejs/eslint-config-prettier
],
rules: {
'no-unused-vars': 'off',
@jhlee8804
jhlee8804 / content-editable.js
Last active June 3, 2023 00:58
Get contenteditable plaintext with correct linebreaks
/**
* @see {@link https://stephenhaney.com/2020/get-contenteditable-plaintext-with-correct-linebreaks}
* @see {@link https://github.com/StephenHaney/stephenhaney/issues/6}
*/
function parseValueFromContentEditable(e) {
let newValue = ''
let isOnFreshLine = true
function parseChildNodesForValueAndLines(childNodes) {
for (let i = 0; i < childNodes.length; i++) {
SELECT DISTINCT object_name(id)
FROM syscomments
WHERE TEXT like '%내용%'
ORDER BY object_name(id)
@jhlee8804
jhlee8804 / slimdown.js
Created June 9, 2018 16:42 — forked from renehamburger/slimdown.js
slimdown.js
'use strict';
/**
* Javascript version of https://gist.github.com/jbroadway/2836900
*
* Slimdown - A very basic regex-based Markdown parser. Supports the
* following elements (and can be extended via Slimdown::add_rule()):
*
* - Headers
* - Links
public class SwaggerConfig
{
public static void Register()
{
var thisAssembly = typeof(SwaggerConfig).Assembly;
GlobalConfiguration.Configuration
.EnableSwagger(c =>
{
c.SchemaFilter<SwaggerSchemaExample>();
$ lsof -n -i4TCP:$PORT | grep LISTEN
$ lsof -n -iTCP:$PORT | grep LISTEN
$ lsof -n -i:$PORT | grep LISTEN
# http://editorconfig.org
root = true
[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
@jhlee8804
jhlee8804 / coinone_chat_shrink.js
Last active November 6, 2017 15:09
코인원 채팅 메시지 개수 줄이기
var $chatList = $('.chat_list');
if ($chatList.length > 0) {
setInterval(function () {
var controller = angular.element($chatList).scope(),
messages = controller.messages,
count = messages.length,
limit = 100;
if (count > limit) {
var offset = count - limit;
'use strict';
(function () {
if (!String.prototype.format) {
// like a c# string.format method
// usage: "{0} of {1}".format('book', 'desk');
String.prototype.format = function () {
var args = arguments;
return this.replace(/{(\d+)}/g, function (match, number) {
return typeof args[number] != 'undefined' ? args[number] : 'undefined';
# vm 속도가 느린 경우 다음 내용을 vmx 파일 하단에 추가한다. (http://hotman.tistory.com/entry/VMWare-%EC%97%90-Mac-OSX-%EC%84%A4%EC%B9%98-%ED%9B%84-%EA%B7%B8%EB%9E%98%ED%94%BD-%EC%84%A4%EC%A0%95)
mksenable3d = "TRUE"
svga.vramSize = "536870912"
vmmouse.present = "FALSE"