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
<div class="form-group"> | |
<label class="control-label" for="inputError1">Input with error</label> | |
<input type="text" class="form-control is-invalid" id="inputError1"> | |
<div class="invalid-feedback">Error message</span> | |
</div> |
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
require 'benchmark/ips' | |
require 'benchmark/memory' | |
require 'set' | |
SIZE = 10_000 | |
def get_number | |
rand(1000) | |
end |
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
require 'benchmark/ips' | |
require 'benchmark/memory' | |
require 'set' | |
SIZE = 10_000 | |
FILES = Array.new(100) do | |
dir = rand(2) == 1 ? Dir.pwd : '/other' | |
dir << '/gems' unless rand(3) == 1 | |
name = [*('A'..'Z')].sample(8).join |