정규식을 조금 더 쉽게 배울 수 있는 사이트 스탭별로 진행하다보면 정규식을 쉽게 습득할 수 있을 듯 하다. https://regexlearn.com Regex Learn - Step by step, from zero to advanced. Learn Regular Expressions, abbreviated as RegEx or RegExp, are a string of characters created within the framework of RegEx syntax rules. You can easily manage your data with RegEx, which uses commands like finding, matching, and editing. Regex can be used regexle..
![](http://i1.daumcdn.net/thumb/C148x148/?fname=https://blog.kakaocdn.net/dn/KCEW1/btrbW3sptRf/vmqvFhgrk4v4uveIcQcOV0/img.png)
기본적으로 사용할 수 있는 Scalar 타입은 정해져있다. //http://webonyx.github.io/graphql-php/type-definitions/scalars/ use GraphQL\Type\Definition\Type; // Built-in Scalar types: Type::string(); // String type Type::int(); // Int type Type::float(); // Float type Type::boolean(); // Boolean type Type::id(); // ID type 그 외에 필요한 타입은 커스텀하여 사용하여야하는데, 대표적으로 Date, DateTime 타입이 없는지 아쉬운 부분이다. 그래도 친절하게 필요한 타입을 정의하여 사용할 수 있도록..
![](http://i1.daumcdn.net/thumb/C148x148/?fname=https://blog.kakaocdn.net/dn/AFpYL/btrbhYSaLmr/Da9ArPvrRWmIK3kXvXVFIk/img.png)
Array 중복제거하는 방법 보통 filter를 주로 사용하였으나 다른 방법이 있는지 찾아보았다. # Filter const array = ['a' , 1, 2, 'a' , 'a', 3]; array.filter((item, index) => array.indexOf(item) === index); # Set const array = ['a' , 1, 2, 'a' , 'a', 3]; [...new Set(array)]; //or Array.from(new Set(array)); # Reduce const array = ['a' , 1, 2, 'a' , 'a', 3]; array..
![](http://i1.daumcdn.net/thumb/C148x148/?fname=https://blog.kakaocdn.net/dn/oVakM/btq9MEs9pWr/9tTkgupZy1BSjaoAfhSP1k/img.png)
생각없이 사용하다 질문 받게되어 foreach, for, map 에 대해 확인해보았다. # for 조건문이 충족할 떄까지 반복 수행하다 break; 만나게 되면 종료된다. for (let i=0; i 5) { break; } } /* 0 1 2 3 4 5 6 */ # forEach 배열의 모든 요소를 순회, return 없음. 외부 값이나 메소드 호출 let arr = [1,2,3,4] let result = arr.forEach(function(item) { console.log(item+1) return item+1 }) console.log(result) /* result 2 3 4 5 undefined */ # map forEach와 동일하나 return 가능. let arr = [1,2,3,4]..
![](http://i1.daumcdn.net/thumb/C148x148/?fname=https://blog.kakaocdn.net/dn/w2Cqc/btq6oClS5a5/yWnLOtNKe0t8GksyYMy8D0/img.png)
# Composer 설치 # composer 설치해준다. php5.6 이상에서 사용할 수 있음. composer require webonyx/graphql-php # Core/Controller.php class Graphql_Controller extends CI_Controller { public function __construct() { parent::__construct(); } public function response($schema=null) { try{ $input = json_decode(file_get_contents('php://input'), true); $query = $input['query']; $variableValues = isset($input['variables']) ..
#MAILTO 환경 변수 Link to MAILTO 환경 변수 cron 은 MAILTO 환경 변수가 있고 공백이 아닐 경우 MAILTO 에 지정한 이메일 주소에 작업 결과를 보고합니다. #1분마다 df 의 결과를 foo@bar.com 에 보내게 됩니다. MAILTO="foo@bar.com" * * * * * df -h MAILTO 변수가 있고 값이 비어 있을 경우는 메일을 보내지 않습니다. #위와 같이 설정한 경우 df 의 결과에 대해서 메일을 보내지 않습니다. MAILTO="" * * * * * df -h MAILTO 환경 변수가 없을 경우 cron 작업의 소유자에게 메일을 전송합니다. cron 작업이 실패했을 경우에만 메일을 보내려면 MAILTO 에 수령인 정보를 설정한 후에 표준 출력(STDOU..
마크다운? Markdown은 텍스트 기반의 마크업언어로 2004년 존그루버에 의해 만들어졌으며 쉽게 쓰고 읽을 수 있으며 HTML로 변환이 가능하다. 특수기호와 문자를 이용한 매우 간단한 구조의 문법을 사용하여 웹에서도 보다 빠르게 컨텐츠를 작성하고 보다 직관적으로 인식할 수 있다. 마크다운이 최근 각광받기 시작한 이유는 깃헙(https://github.com) 덕분이다. 깃헙의 저장소Repository에 관한 정보를 기록하는 README.md는 깃헙을 사용하는 사람이라면 누구나 가장 먼저 접하게 되는 마크다운 문서였다. 마크다운을 통해서 설치방법, 소스코드 설명, 이슈 등을 간단하게 기록하고 가독성을 높일 수 있다는 강점이 부각되면서 점점 여러 곳으로 퍼져가게 된다. 1.Headers 제목 This i..
Axios 를 통해서 파일 다운로드 하기. //response blob or arraybuffer this.$axios({ method: 'post', url: url, responseType: 'blob', data: paramter }).then(res => { //header content-disposition에서 filename 추출. const name = res.headers['content-disposition'].split('filename=')[1] //IE11에서 blob처리 오류로 인해 분기처리 if (window.navigator && window.navigator.msSaveOrOpenBlob) { const blob = res.data window.navigator.msSaveO..
- Total
- Today
- Yesterday
- graphql-php
- 정규식
- 나는욕심쟁이
- addMonth
- 정의
- 둘이상인증한번에사용하기
- vim
- 메일
- composer-self-update
- laravel-test
- POP3
- session+token authorize
- php
- graphql
- Python
- Laravel
- 라라벨
- redis
- php-laravel
- MySQL
- addMonthWithoutOverflow
- exception-test
- VIM-COMMAND
- php-composer
- aaa패턴
- django
- composer-install
- 테스트_다중트랜잭션
- 자바스크립트
- composite-primarykey