This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let googleFontUrl = "https://fonts.googleapis.com/css2?family=Rubik:wght@900&family=Roboto:wght@700&family=Josefin+Sans:wght@700&family=Raleway:ital,wght@1,800&family=Inconsolata:wght@400&family=Nunito:wght@400&family=Oswald:wght@400&family=Righteous:wght@400&family=Bitter:wght@700&family=Nunito:wght@700&family=Scheherazade:wght@400&family=Noto+Sans:wght@400&family=Nova+Round:wght@400&family=Lato:wght@400&family=Noto+Sans:wght@700&family=Playfair+Display:wght@700&family=Seymour+One:wght@400&family=Arvo:wght@700&family=Poppins:wght@700&family=Lato:wght@900&family=Open+Sans:wght@400&family=Pacifico:wght@400&family=Josefin+Sans:wght@400&family=Arvo:wght@400&family=Playfair+Display:wght@400&family=Oswald:wght@700&family=Zeyada:wght@400&family=Montserrat+Alternates:wght@600&family=Poppins:wght@400&family=Ubuntu:wght@400&family=Roboto:wght@400&family=Poppins:wght@800&family=Rubik:wght@400&family=Bangers:wght@400&family=Concert+One:wght@400&family=Open+Sans:wght@700&family=Montserrat:wght@800&family=Dancing+Script:w |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//when you export canvas.toJSON(), the object will cointain `your_custom_attribute` | |
//{“objects”: [{“src”: “”, “your_custom_attribute”: “”, “type”: “image”, …}, {}], “version”: “2.0.0-rc.4” } | |
fabric.Object.prototype.toObject = (function (toObject) { | |
return function (propertiesToInclude) { | |
propertiesToInclude = (propertiesToInclude || []).concat( | |
['your_custom_attribute', ...] | |
); | |
return toObject.apply(this, [propertiesToInclude]); | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ruby:2.3.1 | |
# Install dependencies | |
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs | |
# Set an environment variable where the Rails app is installed to inside of Docker image: | |
ENV RAILS_ROOT /var/www/app_name | |
RUN mkdir -p $RAILS_ROOT | |
# Set working directory, where the commands will be ran: |