$ echo 'gem "webpacker"' >> Gemfile
$ bundle install
$ rails webpacker:install
$ yarn add [email protected] jquery popper.js
diff --git a/config/webpack/environment.js b/config/webpack/environment.js
index d16d9af..86bf1a7 100644
/** | |
* NOTE: this specifically works if the house is for sale since it renders differently. | |
* This will download the highest resolution available per image. | |
*/ | |
/** | |
* STEP 1: Make sure to *SCROLL* through all images so they appear on DOM. | |
* No need to click any images. |
/* preventScrollWhenSoftKeyboardAppearsIfThereIsPlentyOfRoom(event) | |
* | |
* Attach this handler to `touchstart` on any UI control that brings up the keyboard when you don't want iOS | |
* MobileSafari to scroll when a user taps it. Assumes that the input is near the top of the page and the user has | |
* not scrolled down (specific to my case, sorry!) | |
* | |
* requires top-level CSS directives so we can add it to the body: | |
* ``` | |
* .prevent-ios-focus-scrolling { | |
* position: fixed; |
version: '3' | |
services: | |
db: | |
image: mysql:5.7 | |
volumes: | |
- site_db_data:/var/lib/mysql | |
restart: always | |
ports: | |
# bind to host port so we can run mysql tools on host |
# Clone entire site. | |
wget --content-disposition --execute robots=off --recursive --no-parent --continue --no-clobber http://example.com | |
# Remove query string from a static resource. | |
for i in `find $1 -type f -name "*\?*"`; do mv $i `echo $i | cut -d? -f1`; done |
$ echo 'gem "webpacker"' >> Gemfile
$ bundle install
$ rails webpacker:install
$ yarn add [email protected] jquery popper.js
diff --git a/config/webpack/environment.js b/config/webpack/environment.js
index d16d9af..86bf1a7 100644
version: '2' | |
services: | |
db: | |
image: mysql:5.7 | |
volumes: | |
- db_data:/var/lib/mysql | |
restart: always | |
environment: | |
MYSQL_ROOT_PASSWORD: somewordpress |
container_commands: | |
01install-splunk: | |
command: /usr/local/bin/install-splunk.sh | |
02set-splunk-server-host: | |
command: /usr/local/bin/set_splunk_server_host.sh "$SPLUNK_SERVER_HOST" | |
03add-logs-to-splunk: | |
command: /usr/local/bin/add_logs_to_splunk.sh "$ENVIRONMENT_NAME" | |
cwd: /root | |
ignoreErrors: false | |
files: |
#!/bin/bash | |
cat $(find app/assets/stylesheets/ -type f) | | |
grep -Eo '\.[a-z]+[a-z0-9_-]*' | sort | uniq | sed s/.// | | |
while read CSS; do | |
if ! grep -Erqi "([^(remove|has)]?class[(:|=|[:space:]*=>[:space:]*)]*[[:space:]\W]*[(\"|')]*[-a-z0-9[:space:]]*$CSS|\\.$CSS\b)" app/views/ vendor/assets/ app/assets/javascripts/; then | |
echo $CSS >> unused.scss; | |
fi | |
done |