브런치와 함께 콧수염 템플릿을 사용하고 싶습니다. 이건 내 config.coffee 파일입니다브런치에서 콧수염 템플릿을 만드는 법
{languages, plugins} = require 'brunch-extensions'
# Make config loadable via require() for brunch.
exports.config =
# Available plugins:
# * AssetsPlugin: copy `app/assets` contents to `build/`
plugins: [plugins.AssetsPlugin]
# Contains a list of output filenames that your application would generate.
# Format:
#
# 'filename':
# languages:
# 'regExp, with which input files will be matched': language class
# order:
# before: [files, that would be loaded before anything else]
# after: [files, that would be loaded after anything else]
#
files:
'scripts/app.js':
languages:
'\.js$': languages.JavaScriptLanguage
'\.coffee$': languages.CoffeeScriptLanguage
'\.eco$': languages.EcoLanguage
'\.mustache$': languages.HoganLanguage
order:
before: [
'vendor/scripts/console-helper.js'
'vendor/scripts/jquery-1.7.js'
'vendor/scripts/underscore-1.1.7.js'
'vendor/scripts/backbone-0.5.3.js'
]
'styles/app.css':
languages:
'\.css$': languages.CSSLanguage
'\.styl$': languages.StylusLanguage
order:
before: ['vendor/styles/normalize.css']
after: ['vendor/styles/helpers.css']
그러나 brunch watch
를 시작할 때 나는 다음과 같은 오류가 발생했습니다 :
[17:27:45]: [Brunch]: cannot parse config entry
config.files['scripts/app.js'].languages['.mustache$']: TypeError: undefined is not a function.
이것을 알아낼 수 있었습니까? – jsf
아니요. 언어 폴더에서 아무런 참조를 찾을 수 없어서 콧수염지지를 떨어 뜨리는 것 같습니다. –