33 Matching Annotations
- Last 7 days
-
trailblazer.to trailblazer.to
-
The Track() function will snap the output to the next task that is “magnetic to” the track’s semantic.
-
-
stackoverflow.com stackoverflow.com
-
The idea of the script is this: most of the important logic runs in a subshell which is piped through tee and to a logfile, so I don't have to tee every single line of the main logic to get it all logged.
-
-
github.com github.com
-
Record filters allow you to require an instance of a particular class (or one of its subclasses) or a value that can be used to locate an instance of the object. If the value does not match, it will call find on the class of the record. This is particularly useful when working with ActiveRecord objects.
-
- Feb 2021
-
github.com github.com
-
def initialize(attributes=nil) self.assign_attributes(attributes) end
-
-
-
As I reported in #10, error keys get duplicated and we should namespace them. This code behaves right like AR::Base accept_nested_attributes
Tags
Annotators
URL
-
-
-
Jan 2021. I use a small, dedicated enterprise grade SSD as a swap drive. These enterprise drives can be bought for as little as $80 for 240GB right now, and are 3D nand with load leveling and other valuable improvements for swap. By using the drive only for swap, you pretty much guarantee it won’t affect your expensive terabyte level data drive should it fail, and you still get the performance of SSD. Estimates for very heavy use are about 2 1/2 years.
-
- Jan 2021
-
-
Maybe $$slots like $$props? My use case is that I'd like to wrap a slot's content in an element that applies styling that I'd like absent without the slotted content. Something like this: {#if $$slots.description} <div class="description"> <slot name="description"></slot> </div> {/if}
-
-
www.wnycstudios.org www.wnycstudios.org
-
we had to change society
yep
-
-
material.io material.io
-
Small components can set the size of their corner shape using a percentage of the absolute height of the component. This means the corner shape will change as the component height changes.
-
-
css-tricks.com css-tricks.com
-
Some may feel that the presence of the download attribute is redundant when applied to links the browser already knows to store. I disagree.
-
- Dec 2020
-
github.com github.com
-
The only solution that I can see is to ensure that each user gets their own set of stores for each server-rendered page. We can achieve this with the context API, and expose the stores like so: <script> import { stores } from '@sapper/app'; const { page, preloading, session } = stores(); </script> Calling stores() outside component initialisation would be an error.
Good solution.
-
-
sapper.svelte.dev sapper.svelte.dev
-
Preload functions are typically used to load data that the page depends on, hence its name. This avoids the user seeing the page update as it loads, as is typically the case with client-side loading.
-
-
www.npmjs.com www.npmjs.com
-
# fix a bug in one of your dependencies vim node_modules/some-package/brokenFile.js # run patch-package to create a .patch file npx patch-package some-package
I love how directly this allows you to make the change -- directly on the source file itself -- and then patch-package does the actual work of generating a patch from it. Brilliant.
Tags
Annotators
URL
-
-
github.com github.com
-
Maybe something more neutral just meaning a virtual element / no-element container would better express the intention? And regarding the syntax, maybe it would also feel less repetitive / boilerplaty than <svelte:slot slot="name" />... Maybe something like <svelte:fragment slot="name"> or <svelte:virtual slot="name">?
-
- Nov 2020
-
stackoverflow.com stackoverflow.com
-
I would suggest that if you want the behaviour you get when you specify initial-scale=1, then specify initial-scale=1.
-
-
github.com github.com
-
That said, supporting this syntax on elements as well as components could make sense.
Tags
Annotators
URL
-
- Oct 2020
-
github.com github.com
-
Start by reading this post (Final Form + Fonk)
-
-
github.com github.com
-
I too have been confused by behavior like this. Perhaps a clearly defined way to isolate atomic units with synchronous reactivity would help those of us still working through the idiosyncrasies of reactivity.
-
-
medium.com medium.com
-
But for big projects it should work out to just apply this techniques to certain sub-folders in your project where this problems occurs, as-if they are stand alone libraries.
-
-
stackoverflow.com stackoverflow.com
-
Restart from scratch. Create a new program, adding in only what is needed to see the problem. Use simple, descriptive names for functions and variables – don’t copy the names you’re using in your existing code.
-
Divide and conquer. If you’re not sure what the source of the problem is, start removing code a bit at a time until the problem disappears – then add the last part back.
-
-
-
This would be like an executable proposal. I understand that it's beyond the original intent of having canonical patterns on the Svelte site, but it would facilitate the community to express their own patterns. Now that we have markdown preprocessors , the documentation itself can be an app.
-
I'm suggesting that the cookbook apps be self-contained & forkable. 3rd parties could host their own cookbook recipes, possibly using a forked cookbook from an already established pattern.
-
-
developer.mozilla.org developer.mozilla.org
-
strict-origin: Only send the origin of the document as the referrer when the protocol security level stays the same (e.g. HTTPS→HTTPS), but don't send it to a less secure destination (e.g. HTTPS→HTTP).
-
- Sep 2020
-
stackoverflow.com stackoverflow.com
-
From npm@5.2.0, npm ships with npx package which lets you run commands from a local node_modules/.bin or from a central cache.
-
By default, npx will check whether <command> exists in $PATH, or in the local project binaries, and execute that. Calling npx <command> when <command> isn't already in your $PATH will automatically install a package with that name from the NPM registry for you, and invoke it. When it's done, the installed package won’t be anywhere in your globals, so you won’t have to worry about pollution in the long-term. You can prevent this behaviour by providing --no-install option.
-
-
github.com github.com
-
That is, if I remove class={className} from the Child component, and/or remove the class/className prop entirely, then the class:active syntax doesn't have any effect since nothing is rendering the class prop anywhere.
Tags
Annotators
URL
-
- Aug 2020
-
signalvnoise.com signalvnoise.com
-
I used to be a staunch defender of proper reply styles, even for casual emails. Insert your replies below the relevant paragraph and trim the exchange to be just about the matters of discussion.
-
- Jul 2020
-
boards.straightdope.com boards.straightdope.com
-
if British Army gunners are doing a countdown before making something go bang, they actually leave out Five in case anyone mishears it as “Fire”.
-
- May 2020
-
support.google.com support.google.com
-
You should then also create a new View and apply the following filter so as to be able to tell apart which domain a particular pageview occurred onFilter Type: Custom filter > AdvancedField A --> Extract A: Hostname = (.*)Field B --> Extract B: Request URI = (.*)Output To --> Constructor: Request URI = $A1$B1
-
-
-
It would be best to offer an official way to allow installing local, unsigned extensions, and make the option configurable only by root, while also showing appropiate warnings about the potential risks of installing unsigned extensions.
-
- Apr 2020
-
github.com github.com
-
One suggestion is to check user's passwords when they log in and you have the plain text password to hand. That way you can also take them through a reset password flow as they log in if their password has been pwned.
-