Comments (7)
No prob. I'll have to take a look at this in a few days. In the meantime I'm happy to accept a pull request
from handlebars-helpers.
Would something as simple as this work. It would need the utils folder too. I don't know how to do this dynamically (non-hard coded file names) with grunt.
uglify: {
my_target: {
files: {
'lib/hh.min.js': ['lib/helper-lib.js', "lib/helpers/helpers-code.js", "lib/helpers/helpers-collections.js", "lib/helpers/helpers-comparisons.js", "lib/helpers/helpers-data.js", "lib/helpers/helpers-dates.js", "lib/helpers/helpers-html.js", "lib/helpers/helpers-inflections.js", "lib/helpers/helpers-logging.js", "lib/helpers/helpers-markdown.js", "lib/helpers/helpers-math.js", "lib/helpers/helpers-miscellaneous.js", "lib/helpers/helpers-numbers.js", "lib/helpers/helpers-path.js", "lib/helpers/helpers-strings.js", "lib/helpers/helpers-url.js", "lib/helpers/helpers.js"]
}
}
},
from handlebars-helpers.
@gourneau I'm not sure if it's that simple. The project is using require
right now to load in all those other files. I think it would need to be run through browserify or something like that to make it work outside of node. I haven't used those tools yet, so I'm not sure how the work. Also, some of our helpers rely on other node libraries.
@jonschlinkert and I have been talking about refactoring the helper source so we can make it easier to use in other template engines, and I think this will include having a browser specific version, using one of the tools out there or just making sure it works.
from handlebars-helpers.
Yeah, it would look like this:
uglify: {
my_target: {
files: {
'lib/helpers.min.js': [
'lib/helper-lib.js',
'lib/helpers/helpers-*.js'
'lib/helpers/helpers.js'
]
}
}
},
What env would you use them in? do the helpers need to be unwrapped?
from handlebars-helpers.
lol looks like we were thinking the same thing at the same time
from handlebars-helpers.
😱
We can always try to use uglify and see what happens.
from handlebars-helpers.
technically this is a duplicate of this #36, let's continue this discussion there
from handlebars-helpers.
Related Issues (20)
- Comparation(#compare var1 "==" var2) with two variables doesn't work HOT 1
- Upgrade for new versions of the related plugins HOT 1
- does not export a 'register' function, cannot import HOT 1
- Create SECURITY.md
- Not splitting string by line breaks '\n' HOT 1
- todo: merge updates from https://github.com/Budibase/handlebars-helpers HOT 3
- Markdown Helper is broken...
- Vulnerability found (due to highlight.js) HOT 3
- isLast in nested forEach
- Titleize handlebar doesn't titleize input string correctly.
- Request: encode to hex HOT 1
- If loading all helpers the String helper reverse overrides the Array helper reverse. HOT 2
- An examples of working out averages on columns
- Handle empty fields
- String helper `split` doesn't split by empty string.
- This package does not install
- Fumanchu - A supported Handlebar + Handlebars-Helpers together! HOT 4
- query online
- Dead? Process to transfer ownership?
- Dependency "ent" uses deprecated Node punycode module
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from handlebars-helpers.