Integrity is the angel watching over your shoulder while you code. As soon as you push your commits, it builds...
...origin requests. It defines under which circumstances a cookie should be sent to the server, putting cookies into three different classes: SameSite=None Send the cookie whenever a request is...
...Eventually you will want want the same detection logic to be available on both server and client side. This card shows how to get a Ruby method touch_device? for...
...code, it can just merge all files together. You may need to restart your server if you add files to config/locale. Using subfolders You can also use subfolders, but then...
Getting an entire test suite green can be a tedious task which involves frequent switches between the CLI that is...
...use to describe nontrivial migrations in Rails / ActiveRecord. Note that the techniques below should serve you well for tables with many thousand rows. Once your database tables grows to millions...
...an exception has no mapping, Rails will assume a status code of 500 (internal server error) and will render a red "We're sorry, but something went wrong"
You can choose not to care. Since e.g. making JSON requests for HTML services is not supported use of your page, you don't have to support them with...
...Not found error, which is slightly less correct than a 406, but will serve your purpose. Option: Check the format in your actions You can write something like this in...
...maximum number of Passenger workers and Sidekiq worker. If you have a shared database server many possible connections are "expensive", so setting the pool size to a very high number...
...is no good idea (also consider the number of servers you when calculating the total number of possible connections for the shared database server). Blowing up the fail inbox: If...
...a custom pretty_inspect as well. It's fairly simple to do and can serve as a fallback if pretty-printing is not applicable. This can also be an alternative...
...where I had to export records from a local database, transfer it to a server and import it in the server database. 1. export def dump_to_file(list)
## Development Describe how to get started with the project. Document employed 3rd party services and how to use them, how to start a development server – just about
...value and produce a lost update. The Postgres-native fix is to compute the increment server-side inside an atomic INSERT...
...ON CONFLICT DO UPDATE statement and gate it by...
...already entered something into the next field before Unpoly updates that field with a server response, discarding your changes. The steps I wait for active ajax requests to complete (if...
...which hold time zone information and Time.now only in those that run with the server's time. If you don't, bad things can and will happen. More information can...
defined by ActionDispatch::ExceptionWrapper.rescue_responses. In the event of an unexpected internal server error, the exception that caused the error will still be raised within the test so...
...pages, so to test it in development, you will have to start your development server with SSL...
up.util.isEqual([1, 2], [1, 2]) // => true If you are writing server-side code in Node.js you can use isDeepStrictEqual(): import { isDeepStrictEqual } from 'util' isDeepStrictEqual([1, 2], [2, 3]) // => false...
...received in response to a POST (or PUT/DELETE), the client should presume that the server has received the data and should issue a new GET request to the given URI...
...the PDF additional assets (CSS, images, Javascripts) are required When using a singlethreaded development server like Thin there is no additional worker process available to deliver those assets.
...set config.allow_concurrency = true (default in Rails 4) Note that this allows concurrent requests served from the same process using threads. This might cause unexpected behavior if your application or...
...logs all system calls performed by a process. To do this, start your rails server using something like DISABLE_SPRING=1 strace -e trace=file -f bin/rails s
...gems for e.g. the Ruby version 2.6.5 are installed in this directory on our servers (relative to the current app directory) ../shared/bundle/ruby/2.6.0/gems As you can see, the same gems are...
...the patch level of the .ruby-version in the current release directory of all servers of that deployment target to the new version and deploy again. Because on the first...
...font-awesome": "4.7.x", "jquery": "2.2.4", "marked": "0.3.2", "select2": "./vendor/asset-libs/select2", }, "devDependencies": { "webpack-dev-server": "3.x" }, "resolutions": { "jquery": "2.2.4" } } 6. Merge the content of the application.js and application.css to the...
...rake assets:precompile. Remember to remove the folder public/packs afterwards. 11. Configure Capistrano and servers such that all servers share assets 12. Add a binstub for yarn if it's...
...boxes are usually built by observing changes in a text field, and querying the server via AJAX for search results or suggestions when the field has changed. A common problem...
...field for changes every 0.75 seconds or longer. It will still fail when the server is busy or on flaky connections. A cleaner solution would be to check whether a...