Skip to content

Instantly share code, notes, and snippets.

View germsvel's full-sized avatar

German Velasco germsvel

View GitHub Profile

Styling a select tag can be difficult.

Here are some styles that make it okay looking without having to resort to turning it into a ul and using js to handle interaction.

<span class="custom-dropdown">
  <select class="custom-dropdown__select">
    <option value="option1">Option 1</value>
    <option value="option2">Option 2</value>
class ProgressBar
# Prints progress like this:
# Progress: (15%) [==== ]
def initialize(total)
@total = total
@counter = 0
@bar_width = 50
end
@germsvel
germsvel / .projections.json
Last active November 12, 2024 13:36
Elixir/Phoenix basic projections
{
"lib/**/views/*_view.ex": {
"type": "view",
"alternate": "test/{dirname}/views/{basename}_view_test.exs",
"template": [
"defmodule {dirname|camelcase|capitalize}.{basename|camelcase|capitalize}View do",
" use {dirname|camelcase|capitalize}, :view",
"end"
]
},