SDïŒLF
ãã©ã°ã€ã³ããªããã°ãBracketsã¯ä»ã®ãšãã£ã¿ãŒãããåªããŠããŸãããå°ãªããšãè©ŠããŠã¿ãŠãã ããã
ã¯ããã«
å°ãåãŸã§ã ãã©ã±ããç·šéè ã«é¢ããå€ãã®èšäºãäœããã®åœ¢ã§Habréã§å ¬éãããŸããã å€ãã®äººãããã«ããªãå ¬æ£ãªè³ªåãããŸããã
- ïŒ EDITOR_NAMEïŒ ãããåªããŠããã®ã¯ãªãã§ããïŒ
- ãã©ã°ã€ã³ã¯ãããããããŸããïŒ
- é£çµ¡ãã䟡å€ã¯ãããŸããããããšãæåãªIDEãŸãã¯ããã¹ããšãã£ã¿ã䜿çšããæ¹ãè¯ãã§ããããïŒ
ãã®èšäºãèªãã åŸã誰ãããããã®è³ªåã«å¯Ÿããçããèªåã§èŠã€ããããããšãé¡ã£ãŠããŸãã
ãããã«äœ¿ãããæ©èœ
Bracketsã¯ããã¹ããšãã£ã¿ãŒãšããŠäœçœ®ä»ããããŠããŸãããå®éã«ã¯ãæ¬æ ŒçãªIDEã«ãŸããŸã䌌ãŠããŸãã ããã«ããããããããã®ãšãã£ã¿ãŒã®åºæ¬çãªã€ã³ã¹ããŒã«ã§åŸããããã®ã«ã€ããŠèšãå¿ èŠããããŸãã
- ã©ã€ããã¬ãã¥ãŒãã©ã°ã€ã³-Google Chromeã§ã®ã¿åäœããŸãã ãšãã£ã¿ãŒã§ã³ãŒãã«å€æŽãå ããŸã-å€æŽã¯ãã©ãŠã¶ãŒãŠã£ã³ããŠã«èªåçã«è¡šç€ºãããŸã
- æ§æã®åŒ·èª¿è¡šç€º
- CSSãJSãããã³HTMLãã¡ã€ã«ãç·šéããããã®ãã³ã
- ããªã«æåã®äžåšçšãªè¡šç€ºã 次ã®ãªãªãŒã¹ã®ããããã§ä¿®æ£ããããšãçŽæããŸãã çŸåšãããã€ãã®åé¿çããããŸããããã®è©³çŽ°ã«ã€ããŠã¯ä»¥äžãã芧ãã ããã
ãã®ããã¹ããšãã£ã¿ãŒãWEBéçºçšã®åŒ·åãªããã»ããµãŒã«å€ããããšãã§ããã®ã¯ãèšå€§ãªæ°ã®ãã©ã°ã€ã³ã§ãã 次ã«ãæ©èœã®èª¬æãèšèŒãããªã¹ããäœæããŸãã ç§ã¯ã«ã¿ãã°ã§å©çšå¯èœãªãã¹ãŠã®è¿œå ã«ã€ããŠèª¬æããã®ã§ã¯ãªããç§ãæãã«ãæçšã§èå³æ·±ããã®ã«ã®ã¿çŠç¹ãåœãŠãŸãã
ããã«äœ¿ãããã©ã±ãã
æ±çš
æ¡åŒµæ©èœã®è©äŸ¡
åå¿è ã¯ãã®ã¢ããªã³ãäžçªæåã«çœ®ãããšããå§ãããŸãã ããŸããŸãªåºæºã«åŸã£ãŠã«ã¿ãã°å ã®ä»ã®ã¢ããªã³ãæŽçããããGitHubã®ããŠã³ããŒãæ°ãã¹ã¿ãŒæ°ããã©ãŒã¯æ°ãªã©ã®ããŸããŸãªè¿œå æ å ±ã衚瀺ãããããã®æ¡åŒµæ©èœã®æçšæ§ãå°ãªããšã倧ãŸãã«è©äŸ¡ããããšãã§ããŸãã
ååŸ
ãã©ã±ããgit
ããã«ãããã®ã¯ãã¹ãŠååããéåžžã«æ確ã§ãã ããç¥ãããŠããããŒãžã§ã³ç®¡çã·ã¹ãã ã§äœæ¥ããããã®éåžžã«äŸ¿å©ãªæ¡åŒµæ©èœã
ãã©ã±ããã§ã®Git
ã³ãŒãã®æãããã¿
Bracketsã«ãã®ãã©ã°ã€ã³ããªããã°ãæãããã¿ã³ãŒããããã¯ãªã©ã®å¿ èŠãªæ©èœã¯ãããŸããã å·ŠåŽã«èšå®ãããšãè¡çªå·ã®é£ã«äžè§åœ¢ã衚瀺ãããçŸåšäžèŠãªãã©ã°ã¡ã³ããæããããããšãã§ããŸãã
ã³ãŒãã®æãããã¿
ãšã¡ãã
å ¥éæžã¯å¿ èŠãããŸããããåå¿è ã«ã¯ããã«ã€ããŠåŠã¶ã®ãé¢çœãã§ãããã ãã®ãã©ã°ã€ã³ã«ãããLESSãCSSãããã³HTMLãç·šéããéã®ããã¹ãå ¥åãå€§å¹ ã«é«éåã§ããŸãã
ããšãã°ã次ã®æ§æãå°å ¥ããŸãã
button.btn.btn-primary{}
TabããŒãæŒããšã次ã®ããã«å±éãããŸãã
<button class="btn btn-primary"></button>
ã©ãã
div.btn-toolbar>(button.btn.btn-default{})*3
ã¯ãªãã¯ãããšå±éããŸã
<div class="btn-toolbar"> <button class="btn btn-default"></button> <button class="btn btn-default"></button> <button class="btn btn-default"></button> </div>
ç§ã¯ãã以äžãã¿ãã¬ãããŸãããããã¯Habréã§ãã§ã«å©çšå¯èœãªã¬ãã¥ãŒãèªãããšããå§ãããŸãïŒ
ããããªãZen Codingã ããã«ã¡ã¯ãšã¡ããïŒ
Emmet v1.0ããªãªãŒã¹ãããŸãã
å ¬åŒã®æ瀺 ïŒè±èªïŒããå§ãããŸãã
ã³ãŒãæŠèŠ
ãšãã£ã¿ãŠã£ã³ããŠã®å³åŽã«å°ããªããã«ãããããã¹ãŠã®ã³ãŒãã¯ãé³¥ç°å³ãã§ãã èå³æ·±ããµã€ãã«ããã«è¡ãããšãã§ããŸãã
CodeOverviewãã©ã°ã€ã³ã«å ããŠãããŒã¿çã®BluePrintããããŸãã ã©ã¡ããè¯ãã§ãã-èªåã§æ±ºããŠãã ããã
ã³ãŒãã¬ãã¥ãŒ
ããã¥ã¡ã³ãããŒã«ããŒ
ã¿ãä»ãã€ã³ã¿ãŒãã§ã€ã¹ã«æ £ããŠããŠãããããé¢è±ããããªã人ã®ããã«ïŒä»£ããã«ãBracketsã¯ããªãŒã®äžã«éããŠãããã¡ã€ã«ã®ãªã¹ããæäŸããŸãïŒã
æ¬åŒ§ãã©ã³ã
ãšãã£ã¿ãŒã§ããã¹ãã衚瀺ãããã©ã³ãããªã¹ãããéžæã§ããŸãã ããªã«æåãã©ã®ããã«è¡šç€ºããå§ãããã«æ³šæããŠãã ããã ããã«ãåãæ©èœãæã€ãã©ã°ã€ã³ãããã€ããããŸãã [衚瀺/ããŒã]ã¡ãã¥ãŒé ç®ãéãããšãã§ããŸãããã®ã¡ãã¥ãŒé ç®ã§ã¯ã䜿çšãããã©ã³ããæåã§æå®ã§ããŸãã
ãã©ã³ã
ãã©ã±ããçšã®HTTPãµãŒããŒ
ããŒã«ã«HTTPãµãŒããŒãèµ·åããŠããããžã§ã¯ãããããã°ããŸãã çµã¿èŸŒã¿ã®ã©ã€ããã¬ãã¥ãŒãšã®éãã¯äœã§ããïŒ
- ããã¯LivePreviewã§ã¯ãããŸããã ããŒãžãæåã§æŽæ°ããå¿ èŠããããŸãã
- ãã®ãµãŒããŒã«ã¯ãã·ã¹ãã ã«ã€ã³ã¹ããŒã«ãããŠããä»»æã®ãã©ãŠã¶ãŒããã¢ã¯ã»ã¹ã§ããŸãã IEãšFirefoxã®éçºè ã¯åãã§ããŸãã
ãŸããextensionsãã£ã¬ã¯ããªã«ã¯ãLivePreviewã«äŒŒãStatic Previewãã©ã°ã€ã³ããããŸãããä»ã®ãã©ãŠã¶ãŒã§ãã©ã€ããç·šéãè¡ãããšãã§ããŸãããçŸæç¹ïŒ2014幎11æ8æ¥ïŒã§ã¯ãã©ã±ãããããã³ã°ãããŠããŸãã ããæ£ç¢ºã«èšããšããšãã£ã¿ãŒãäœæ¥ãæ£åžžã«å®äºã§ããªãããã«ããŸããèšå®ãšéããŠãããã¡ã€ã«ã®ãªã¹ããä¿åããŸãã ããããããã®ãšã©ãŒã¯ããã«ä¿®æ£ãããã§ãããããæ¢åã®åé¡ã«ãããç§ã¯ãã®ãã©ã°ã€ã³ããç§ãé ãããŠããŸãã
ãã©ã±ããçšã®ããªã声
ãã©ã±ããã¯Gruntã®ãã©ã°ã€ã³ãæäŸã§ããŸãã ãã®èšå®ã¯å¥ã®ãããã¯ã§ãããæžç±å šäœã§ããããã«ã€ããŠæžããŠããŸãã 2014幎ãGruntãŸãã¯Gulpã䜿çšããªãããšã¯ãéçºè ã®å³ãšè»œèãã®å åã§ããããšã«ãç§ã¯ãã æ°ã¥ããŠããŸãã
ãã¥ãŒãã£ãã¡ã€ããã¥ãŒãã£ãã¡ãŒ
Ctrl + LãŸãã¯Ctrl + Bã®ããŒã®çµã¿åãããæŒãã ãã§ãèšèšãäžååãªJSãŸãã¯HTMLã³ãŒããé©åã«èšèšããããã®ã«å€ãããŸãã åçã§ã¯ããã®ãã©ã°ã€ã³ãé©çšããåãšåŸã®global_main.jsHabréããããŸãã ãããã®ãã©ã°ã€ã³ãLESSã«äœ¿çšããªãã§ãã ããïŒ ã³ãã³ã®åŸã«ã¹ããŒã¹ãæ¿å ¥ãããLESSãã¡ã€ã«ãã³ã³ãã€ã«ãããªããªããŸãã
ã¢ã·ã¹ã¿ã³ãããã¹ãŠèæœãæ©ã§ïŒ
ã¯ã€ãã¯ãµãŒã
åŒãããã«ã¯ãªãã¯ãããšãããã¥ã¡ã³ãå ã®ãã¹ãŠã®åºçŸç®æã匷調衚瀺ãããŸãã æ¡åŒµæ©èœã®äœæè ã¯ãé衚瀺ã«ãªããªãNotepad ++ã«è§ŠçºãããŠããŸãã
ã¡ã¢åž³++ïŒ ãã
SFtpUploadãFTP-Sync
ïŒSïŒFTPãä»ããŠãµãŒããŒã«ãããžã§ã¯ããã¡ã€ã«ãã¢ããããŒãã§ããŸãã 圌ãã¯ããŒã§èªèšŒããæ¹æ³ãç¥ã£ãŠããŸãã
FTPåæãSFtpUpload
ã¬ã€ã¢ãŠããã¶ã€ããŒ
å°ãªãèªåã³ã³ãã€ã«
CSSã®ç·šéã§é çãããããªã人ã®ããã«ãLESSã¯ãã£ãšåã«çºæãããŸããã ãã®ãã©ã°ã€ã³ã䜿çšãããšãä¿åæã«.lessãã¡ã€ã«ãèªåçã«ã³ã³ãã€ã«ã§ããŸãã çŸåšã®ç¶æ ã§ã¯ãå°ãèšå®ãå¿ èŠã§ãã
- .lessãã¡ã€ã«ã®ããããŒã«ã¯ã次ã®ãããªèšè¿°ãå¿
èŠã§ãã
// out: ../css/login.css
.cssåºåãã£ã¬ã¯ããªããªãŒããŒã©ã€ãããå¿ èŠãããå Žåã ãã以å€ã®å Žåã.cssãã¡ã€ã«ã¯.lessãšåãå Žæã«äœæãããŸãããããã¯ããŸãè¯ããããŸããã ãã¡ã€ã«ã®ä»ã®ãã¹ãŠã®LESSèšå®ã¯ããã«ç»é²ãããŸãã - ãããžã§ã¯ãèšå®ã§ã¯ãåŠçããLESSãã¡ã€ã«ãæ瀺çã«æå®ããå¿
èŠããããŸãã ãããè¡ãã«ã¯ã 次ã.brackets.jsonãŸãã¯compile.jsonã«è¿œå ããŸã ïŒã©ã¡ãããããžã§ã¯ãã®ã«ãŒããã£ã¬ã¯ããªã«ãããæåã®ãã¡ã€ã«ã¯Bracketsã«ãã£ãŠèªåçã«äœæãããŸãïŒã
{ "less": [ "static/login/less/login.less", "static/desktop/less/index.less" // LESS- ] }
ãã©ã±ããã®èªåæ¥é èŸ
ãã®ãã©ã°ã€ã³ã®çŽ¹ä»ã¯äžèŠã ãšæããŸãã ãã³ããŒãã¬ãã£ãã¯ã¹ãšå€ããã©ãŠã¶ããµããŒãããããã«ãæ¢åã®CSSãã¡ã€ã«ã«å¿ èŠãªè¿œå ãæ¿å ¥ããŸãã èšå®ã«å¿ããŠãããŸããŸãªçµæãåŸãããšãã§ããŸãã ããªãã·ã³ãã«ãªãªãã·ã§ã³ãŠã£ã³ããŠããããŸãã å®å šãªãªã¹ãã¯GitHubã®ãããžã§ã¯ãããŒãžã«ãããŸã ã
ããããªãºã Autoperefixerèšå®
CSSLintãLESSLintãLESS StyleSheets Formatter
LESSããã³CSSã³ãŒãã®æ¹åã«åœ¹ç«ã€ããã«èšèšããã3ã€ã®ãã©ã°ã€ã³ã ãããã¯å žåçãªééãã§ãããããŸãééãã§ã¯ãããŸããã åçã®äŸã
CSSãšã©ãŒ
HTMLHintãããå€ãã®CSSã³ãŒããã³ããããå€ãã®HTML5ã³ãŒããã³ã
ãã©ã°ã€ã³ã¯ãHTMLãšCSSãç·šéãããšãã«ãããå€ãã®ãã³ããæäŸããŸãã åºæ¬çãªBracketsé ä¿¡ã«ããŸããŸãªæ¹åãšè¿œå ãè¿œå ãããé床ãèæ ®ãããšããããã®ãã©ã°ã€ã³ã®æ©èœãã«ãŒãã«ã«çµ±åãããã®ãåŸ ã€å¿ èŠããããŸãã
ColorHintsããã©ã±ããã«ã©ãŒããã«ãŒ
æåã®ãã®ã¯ããšãã£ã¿ãŒã§ã³ãŒããŸãã¯è²ã®ååã«ã«ãŒãœã«ãåããããšãã³ãã衚瀺ããã°ã©ããŒã·ã§ã³ã衚瀺ã§ããŸãã 2çªç®ã¯ãç®çã®è²ãéžæããããã®ãã¬ãããåãããŠã£ã³ããŠã衚瀺ããŸãã LESSãã¡ã€ã«ãç·šéããéãè²ãå ¥åããåŸã«èªåçã«è¡šç€ºãããªãã£ãå Žåã¯ãè²ãéžæãããŠã£ã³ããŠãCtrl + Alt + Kã§åŒã³åºãå¿ èŠããããŸãã
ã°ã©ããŒã·ã§ã³ãšè²ãå
¥åããããã®ãã³ã
JavaScriptéçºè
JSHintãJSLintãJSHint ConfiguratorãJSLint Configurator
匷å¶ããã ãã§ãªããJavaScriptã§ã³ãŒããäœæããéçºè ã«ãšã£ãŠéåžžã«äŸ¿å©ãªãã©ã°ã€ã³ã JSHintãšJSLintã®ã©ã¡ãããéžæã§ããŸãããäž¡æ¹ã䜿çšããããšãã§ããŸãïŒ2ã€ç®ã¯ãã³ãŒãã«é¢ããŠããåãããããŸãïŒã ååã瀺ãããã«ãã³ã³ãã£ã®ã¥ã¬ãŒã¿ãŒã䜿çšãããšãã³ãŒãããã§ãã¯ããããã®ããŸããŸãªãã©ã¡ãŒã¿ãŒãæ§æã§ããŸããããšãã°ã宣èšãããåã«requirejsé¢æ°ã®äœ¿çšãç¡èŠããŸãã
åãã©ã¡ãŒã¿ãŒãå¿
èŠãªçç±ã¯èª°ããæ¢ã«ç¥ã£ãŠããŸãã
Funcdocr
ãã©ã°ã€ã³ã䜿çšãããšãJSæ©èœããã°ããããã¥ã¡ã³ãåã§ããŸãã
ããšãã°ã次ã®ã³ãŒãããããŸãã
Desktop.prototype.addResizeHandler = function(handler) { if ($.isFunction(handler)) { this.resizeActions.push(handler); } };
é¢æ°å®£èšã®åã«ç«ã£ãŠã/ **ãå ¥åããŸãã EnterããŒãæŒããšãFuncDocrã¯ãã®ã³ã¡ã³ããå±éããå¿ èŠãªãã®ãå ¥åããã ãã®ç©ºçœã眮ãæããŸãã
/** * [[Description]] * @param {[[Type]]} handler [[Description]] */ Desktop.prototype.addResizeHandler = function(handler) { if ($.isFunction(handler)) { this.resizeActions.push(handler); } };
AngularJSã³ãŒããã³ããAngularJS for Brackets
Angularãã£ã¬ã¯ãã£ããå ¥åãããšãã«ãã³ããè¿œå ããŸãã ãã®ãã¬ãŒã ã¯ãŒã¯ã¯åããŠã§ãããããã2ã€ã®ãã©ã°ã€ã³ãå°é家ã®æåŸ ã«å¿ããããšãé¡ã£ãŠããŸãã
JavaScriptèå¥åã®ååãå€æŽ
èå¥åã«ãªããCtrl + RãæŒããæ°ããååãå ¥åããŸã-ã¹ã¯ãªããå ã®å€æ°ã®ãã¹ãŠã®åºçŸã¯èªåçã«ååãå€æŽãããŸãã
è»èã§é£ã¶
ããŸããŸãªèšå®ãšãã©ã¡ãŒã¿ãŒãããããããã©ã±ããã«é¢ããèŠæ ãããã€ããããŸãã æåã§æãéèŠãªã®ã¯é床ã§ãã å€æ°ã®ãã©ã°ã€ã³ãšããã¥ã¡ã³ãã«æ¥ç¶ãããå€ãã®ãã©ã°ã€ã³ã«ãããCSSã¯ããã¥ã¡ã³ãã®ç·šéæã«ããŒã«ãããã®è¡šç€ºãèããé ããå§ããŸãã å Žåã«ãã£ãŠã¯ãJSã¹ã¯ãªãããç·šéããéã«ãšãã£ã¿ãŒã®åå¿ãåŸ ã€å¿ èŠããããŸãã 2ã€ç®ã¯ãããªãäžäŸ¿ãªããã²ãŒã·ã§ã³ããªãŒã§ãã 第äžã«ãäžéšã®ãã©ã°ã€ã³ã¯ãšãã£ã¿ãŒãããã³ã°ãããããšãã£ã¿ãŒãæ£åžžã«éããŠèšå®ãä¿åã§ããªãããã«ããŸãã