- Last 7 days
-
www.youtube.com www.youtube.com
-
in the data center you're dealing with things at the microsc or millisecond scale uh when you move out to the edges of the network you're dealing with seconds and minutes
for - IPFS - etymology - Inter Planetary - designing to avoid large network delay differences over long distances - Juan Benet
-
- Sep 2024
-
stackoverflow.com stackoverflow.com
-
Disable all observers in your test suite by default. They should not be complicating your model tests because they should have separate concerns anyway. You don't need to unit test that observers actually fire, because ActiveRecord's test suite does that, and your integration tests will cover it.
-
- Jul 2024
-
www.mailgun.com www.mailgun.com
-
We want users to unsubscribe to messages they don’t want; we don’t want them to mark them as spam and hurt the reputation of the sender. We have seen by implementing this unsubscribe affordance in the UI that spam marks go down and in some cases are being reduced by 30 to 40%.
-
- May 2024
-
-
how exactly has Europe managed to avoid an American style opioid crisis surprisingly it 00:06:18 turns out we can thank authentic Afghan heroin for the relative lack of deaths
for - question - how EU avoided synthetic opiod crisis until now?
question - how did EU avoid synthetic opiod crisis until now? - answer - authentic Afghan Heroin - but with the crackdown on poppy in Afghanistan, EU drug users are primed to start using synthetic opiods
-
- Apr 2024
-
www.ramotion.com www.ramotion.com
-
What are some of the best practices for kids’ UX design?
-
- Feb 2024
-
unix.stackexchange.com unix.stackexchange.com
-
Well, here’s a non-recursive solution in which the main commands appear only once:
-
Duplicating non-trivial code in both the if and in the else could create unnecessary issues.
-
- Jan 2024
-
gitlab.com gitlab.com
-
That helps us keep GitLab simple as long as we can.
-
-
gitlab.com gitlab.com
-
I feel we need a agreeable definition of work-items. It is getting confusing already. If the goal is to avoid confusion then exceptions must be avoided.
-
-
www.postman.com www.postman.com
-
We want to evolve the API without unnecessary versioning. To be able to do that, the consumer should
-
- Nov 2023
-
github.com github.com
-
// instead of visiting each page and waiting for all // the associated resources to load, we can instead // just issue a simple HTTP request and make an // assertion about the response body cy.request('/admin') .its('body') .should('include', '<h1>Admin</h1>')
instead of cy.visit
-
- Sep 2023
- Jun 2023
-
stackoverflow.com stackoverflow.com
-
Far more preferable is to minimize data structure so that it tends to be normalized and not to have inconsistent states. Then, if a member of a class is changed, it is simply changed, rather than damaged.
-
-
docdrop.org docdrop.orgUntitled1
-
MELODIC STRUCTURES»
https://docdrop.org/pdf/Bergonzi1992Melodic_Structures-4edv1_ocr.pdf/?src=ocr
Melodic Structures (Vol 1) Bergonzi, J 1994
-
- May 2023
-
stackoverflow.com stackoverflow.com
-
I know this is an old question but I just want to comment here: To any extent email addresses ARE case sensitive, most users would be "very unwise" to actively use an email address that requires capitals. They would soon stop using the address because they'd be missing a lot of their mail. (Unless they have a specific reason to make things difficult, and they expect mail only from specific senders they know.) That's because imperfect humans as well as imperfect software exist, (Surprise!) which will assume all email is lowercase, and for this reason these humans and software will send messages using a "lower cased version" of the address regardless of how it was provided to them. If the recipient is unable to receive such messages, it won't be long before they notice they're missing a lot, and switch to a lowercase-only email address, or get their server set up to be case-insensitive.
-
- Mar 2023
-
www.frontiersin.org www.frontiersin.org
-
we propose five cornerstones that help deal with the highlighted issues and categorize unintended consequences.
5 principles for mitigating progress traps - 1) - a priori assessments of potential unintended consequences of policies - should be conducted by - multidisciplinary teams - with as broad a range of expertise as possible. - This would require decision-making - to flex around specific policy challenges - to ensure that decision-makers reflect the problem space in question. - 2) - policy plans made in light of the assessment should be iterative, - with scheduled re-assessments in the future. - As has been discussed above, - knowledge and circumstances change. - New consequences might have since - become manifest or new knowledge developed. - By planning and implementing reviews, - organizational reflexivity and - humility - needs to be built into decision-making systems (e.g., Treasury, 2020).
- 3)
- given the scale of systems
- such as the water-energy-food nexus
- and the potential for infinite variety and nuance of unintended consequences,
- pragmatism necessitates specification of boundaries
- within which assessments are made.
- pragmatism necessitates specification of boundaries
- It should be noted that this can in itself give rise to unintended consequences
- through potential omission of relevant areas.
- Hence, boundary decisions regarding
- where the boundaries lie
- should be regularly revisited (as per 2) above.
- where the boundaries lie
- given the scale of systems
- 4)
- unintended consequences identified
- should be placed in the framework
- with as much consensus among decision-makers as possible.
- should be placed in the framework
- The positioning does not need to be limited to a single point,
- but could be of the form of a distribution of opinions of range
- of knowability and
- avoidability;
- the distribution will be indicative of
- the perspectives and
- opinions of the stakeholders.
- but could be of the form of a distribution of opinions of range
- If a lack of consensus exists on the exact position,
- this can highlight a need to
- seek more diverse expertise, or
- for further research in order to improve consensus, or
- for fragmenting of the issue into
- smaller,
- more readily assessable pieces.
- this can highlight a need to
- unintended consequences identified
- 5)
- there is a need for more active learning
- by decision-makers
- about how to avoid repeating past unintended consequences.
- by decision-makers
- To support this,
- assessment process and
- outcomes should be
- documented and
- used
- to appraise the effectiveness of policy mechanisms,
- with specific attention on outcomes
- beyond those defined by policy objectives and the
- assumptions and
- decisions
- which led to these outcomes.
- beyond those defined by policy objectives and the
- with specific attention on outcomes
- Such appraisals could reflect on
- the scope of the assessment, and
- the effectiveness of specific groups of stakeholders
- in being able to identify potential negative outcomes,
- highlighting gaps in knowledge and limitations in the overall approach.
- in being able to identify potential negative outcomes,
- Additional records of the level of agreement of participants
- would allow for re-evaluation with new learning.
- there is a need for more active learning
- 3)
-
- Dec 2022
- Sep 2022
-
www.codementor.io www.codementor.io
-
Conventions are good, but they are very limited: enforce them too little and the programmer becomes coupled to the code—no one will ever understand what they meant once they are gone. Enforce too much and you will have hour-long debates about every space and colon (true story.) The “habitable zone” is very narrow and easy to miss.
-
-
metalblueberry.github.io metalblueberry.github.io
-
your cognitive load increases with the level of indentation. 1 2 3 4 5 6 7 8 9 10 if r.Method == "GET" { if r.Header.Get("X-API-KEY") == key { // ok return nil }else{ return errors.New("Key is not valid") } } else { return errors.New("Invalid Method") }
-
Avoid indentation levels, If you find yourself with more than 3, you should create a function.
-
-
docs.openvalidation.io docs.openvalidation.io
-
The rules recorded in natural language are readable not only by humans but also by the computer and therefore no longer need to be programmed by a software developer. This task is now taken over by openVALIDATION.
-
-
stackoverflow.com stackoverflow.com
-
This clearly violates DRY, which is the reason why OP asked this question in the first place
-
It appears redundant, and my goal of using $ref is to avoid repeating definitions.
-
-
github.com github.com
-
OAS 3.1 uses all of JSON Schema draft 2020-12 including unevaluatedProperties. You won't find direct references to unevealuatedProperties in the OAS spec because it links to the JSON Schema spec instead of duplicating it's contents.
-
-
github.com github.com
-
Multiple different people have been discussing multiple different problems, and asking for examples of the other problems, talking past each other and generally this thread got to an unreadable point due to this confusion.
-
- Jul 2022
-
github.com github.com
-
Interestingly, Rails doesn't see this in their test suite because they set this value during setup:
-
-
discuss.rubyonrails.org discuss.rubyonrails.org
-
Overriding the ActiveStorage controllers to add authentication or customize behavior is a bit tedious because it requires either: using custom routes, which means losing the nice url helpers provided by active storage copy pasting the routes in the application routes.rb, which is not very DRY.
-
- May 2022
-
serverfault.com serverfault.com
-
Here's another convenient use of try_files, as unconditional redirects to named locations. The named locations are effectively acting as subroutines, saving duplication of code.
-
- Apr 2022
-
twitter.com twitter.com
-
Joshua Weitz. (2021, April 7). The same approaches that work against SARS-CoV-2 work against variants like B.1.1.7: Mask Avoid indoor gatherings Socialize outdoors And, reinforces the need to continue to scale-up vaccine administration to all 16+. [Tweet]. @joshuasweitz. https://twitter.com/joshuasweitz/status/1379820197696180233
-
- Jan 2022
-
-
For example, suppose your API returns a 401 Unauthorized status code with an error description like The access token is expired. In this case, it gives information about the token itself to a potential attacker. The same happens when your API responds with a 403 Forbidden status code and reports the missing scope or privilege.
-
- Nov 2021
-
www.varvet.com www.varvet.com
-
I am firmly convinced that asserting on the state of the interface is in every way superior to asserting on the state of your model objects in a full-stack test.
-
- Sep 2021
-
github.com github.com
-
Use this to load modules whose location is specified in the paths section of tsconfig.json when using webpack. This package provides the functionality of the tsconfig-paths package but as a webpack plug-in. Using this plugin means that you should no longer need to add alias entries in your webpack.config.js which correspond to the paths entries in your tsconfig.json. This plugin creates those alias entries for you, so you don't have to!
-
-
blog.johnnyreilly.com blog.johnnyreilly.com
-
The declarations you make in the tsconfig.json are re-stated in the webpack.config.js. Who wants to maintain two sets of code where one would do? Not me.
-
When I look at the tsconfig.json and the webpack.config.js something occurs to me: I don't like to repeat myself. As well as that, I don't like to repeat myself. It's so... Repetitive.
-
-
stackoverflow.com stackoverflow.com
-
Unfortunately, it's too late to make the question more specific as this would invalidate some of the (good) answers.
-
- Aug 2021
-
stackoverflow.com stackoverflow.com
-
The best way to do this is to derive the type Format from a value like an array which contains all of the Format literals.
-
That should work as expected and not be too verbose (or at least it doesn't repeat string literals anywhere)
-
My question is specifically if there is a way to do user defined type guards using the type itself
-
- Jun 2021
-
stackoverflow.com stackoverflow.com
-
if x.strip('%').isnumeric(): return float(x.strip('%'))/100
-
-
-
HTTP REST seems like an "out of external dependency" way to go.
-
The idea is to avoid additional dependency if it's possible.
-
-
www.mutuallyhuman.com www.mutuallyhuman.com
-
Rather than write new tooling we decided to take advantage of tooling we had in place for our unit tests. Our unit tests already used FactoryBot, a test data generation library, for building up test datasets for a variety of test scenarios. Plus, we had already built up a nice suite of helpers that we coud re-use. By using tools and libraries already a part of the backend technology’s ecosystem we were able to spend less time building additional tooling. We had less code to maintain because of this and more time to work on solving our customer’s pain points.
-
-
docs.gitlab.com docs.gitlab.com
-
These tests should be isolated as much as possible. For example, model methods that don’t do anything with the database shouldn’t need a DB record. Classes that don’t need database records should use stubs/doubles as much as possible.
-
-
docs.gitlab.com docs.gitlab.com
-
A common cause of a large number of created factories is factory cascades, which result when factories create and recreate associations.
-
:js is particularly important to avoid. This must only be used if the feature test requires JavaScript reactivity in the browser. Using a headless browser is much slower than parsing the HTML response from the app.
-
Use Factory Doctor to find cases where database persistence is not needed in a given test.
-
-
docs.gitlab.com docs.gitlab.com
-
Do not test the internal implementation of the child components:
-
-
docs.gitlab.com docs.gitlab.com
-
Another common gotcha is that the specs end up verifying the mock is working. If you are using mocks, the mock should support the test, but not be the target of the test.
-
Don’t test the library
-
Testing the hasMetricTypes computed prop would seem like a given here. But to test if the computed property is returning the length of metricTypes, is testing the Vue library itself. There is no value in this, besides it adding to the test suite.
-
-
stackoverflow.com stackoverflow.com
-
One of the consequences (although arguably not the primary motivation) of DRY is that you tend to end up with chunks of complex code expressed once, with simpler code referencing it throughout the codebase. I can't speak for anyone else, but I consider it a win if I can reduce repetition and tuck it away in some framework or initialisation code. Having a single accessor definition for a commonly used accessor makes me happy - and the new Object class code can be tested to hell and back. The upshot is more beautiful, readable code.
new tag?:
- extract reusable functions to reduce duplication / allow elegant patterns elsewhere
-
-
www.postgresql.org www.postgresql.org
-
Writing json_populate_record in the FROM clause is good practice, since all of the extracted columns are available for use without duplicate function calls.
-
- May 2021
-
interpersonal.stackexchange.com interpersonal.stackexchange.com
-
the problem is that I write a lot of these emails and they are a waste of my and everyone elses time
-
-
stackoverflow.com stackoverflow.com
-
[gripe]Email is supposed to be a text-only medium. I can concede a need for rich text - the occasional bold or italic - but background pictures are just needless bloat.[/gripe]
-
-
hashnode.com hashnode.com
-
But more so, external style cannot be applied to a subsection of a web page unless they force it into an iframe, which has all sorts of issues of it's own which is why external CSS is usually ignored. Inline CSS is often stripped by the tag strippers who don't want you turning things on or off... and media queries shouldn't even play into it since the layout should be controlled by the page it's being shown inside (for webmail) or the client itself, NOT your mail.
-
Whilst I realize the artsy fartsy types get a raging chodo over their goofy PSD based layout asshattery
Tags
- opinionated
- no control over
- HTML email
- colorful language
- email client
- who should control over _?
- HTML email: CSS
- preventing CSS/styles from affecting outside of container (isolation) (global scope)
- HTML email: avoid using
- whose responsibility is it?
- HTML: tables: avoid using
- difficult/hard problem
Annotators
URL
-
-
-
Perhaps the most impressive part of the entire email is the fallback it used for non-WebKit emails —a beautiful grid layout of the carousel that didn’t hide or duplicate any content!
-
-
www.gkogan.co www.gkogan.co
-
They're less likely to go into the "Promotions" tab in Gmail (used by ~16% of all email users), for the same reasons above. From my testing, the plain emails typically end up in the Updates tab and some times even in the primary tab. Of course, the text in the email also affects this.
-
You can use a free spam checker to validate this by testing plain and designed emails.
-
You'll have to use <table> tags—a method long buried by web developers
-
-
www.mail-tester.com www.mail-tester.com
-
rodriguezcommaj.com rodriguezcommaj.com
-
While it’s not quite completely table-free, I’ve managed to get The Intermittent Newsletter down to a single table—one that’s not even visible to non-Microsoft email clients. Along the way, I made an effort to make The Intermittent Newsletter accessible to more readers.
Tags
Annotators
URL
-
- Mar 2021
-
-
Here are my thoughts: making vim startup time shorter is GOOD added complexity - BAD my main concern is with the complexity that gets added to get startup time improvements. User has to tag scripts, and then manually BundleBind to get scripts loaded. This seems like too much hassle(manual involvement) to me. Fixing 1 time thing (startup) we're adding many more (like BundleBinding required scripts once they're used) For instance in my case i don't start Vim often because i'm using --remote-tab-silent option. So i'll get no benefit along with complexity (
-
-
unix.stackexchange.com unix.stackexchange.com
-
I find it convenient to change proxy and other settings through gui window by right-clicking on launcher icon on my desktop. I mostly start slack by clicking desktop launcher, but also want to be able to start it from command line in some cases.
-
-
github.com github.com
-
Or even a simple 1-liner in the Contract that references an AR Model so you don't have to rewrite the validations again in that contract, or have to choose between writing the validations once either in the contract there or in the AR Model?
-
how to have validations in model and some in contract/form object without duplicating
-
-
blog.izs.me blog.izs.me
-
Simplicity is better than anything.
-
-
en.wiktionary.org en.wiktionary.org
-
The customer overspecified the requirements and now we're contractually required to build it this way. Does he think he's an engineer?
-
-
tobeagile.com tobeagile.com
-
The number one problem that I see developers have when practicing test-first development that impedes them from refactoring their code is that they over-specify behavior in their tests. This leads developers to write more tests than are needed, which can become a burden when refactoring code.
-
-
www.chevtek.io www.chevtek.io
-
Write modules quickly, to meet your needs, with just a few tests for compliance. Avoid extensive specifications.
-
Write modules that do one thing well. Write a new module rather than complicate an old one.
.
-
-
www.sitepoint.com www.sitepoint.com
-
The elimination of what is arguably the biggest monoculture in the history of software development would mean that we, the community, could finally take charge of both languages and run-times, and start to iterate and grow these independently of browser/server platforms, vendors, and organizations, all pulling in different directions, struggling for control of standards, and (perhaps most importantly) freeing the entire community of developers from the group pressure of One Language To Rule Them All.
-
JavaScript needs to fly from its comfy nest, and learn to survive on its own, on equal terms with other languages and run-times. It’s time to grow up, kid.
-
If JavaScript were detached from the client and server platforms, the pressure of being a monoculture would be lifted — the next iteration of the JavaScript language or run-time would no longer have to please every developer in the world, but instead could focus on pleasing a much smaller audience of developers who love JavaScript and thrive with it, while enabling others to move to alternative languages or run-times.
Tags
- level playing field
- independent release cycles among peer dependencies
- one size fits all mentality
- programming languages: choosing the best language for the job
- runtime environment
- neutral/unbiased/agnostic
- related but independent projects that can be developed independently
- software freedom
- good idea
- avoid giving partiality/advantage/bias to any specific option
- competition in open-source software
- separation of concerns
- JavaScript: as a process VM
- neutral ground
- programming languages
- single responsibility
Annotators
URL
-
-
github.com github.com
-
This is a copy of the "AMD" document in the repo, kept here to maintain historical links. If this document differs from the one in the repo, the repo version is the correct one.
Why not just make this document empty (besides a link) and link/redirect to the canonical version?
That way it is impossible for them to disagree.
Tags
- avoid duplication
- make it impossible to get wrong/incorrect
- I have a question about this
- avoid duplication: impossible for them to disagree/diverge if there's only one version/copy
- canonical version
- maintaining redirect/copy at old URL in order to maintain historical links (broken links)
Annotators
URL
-
-
www.codetriage.com www.codetriage.com
-
Before a bug can be fixed, it has to be understood and reproduced. For every issue, a maintainer gets, they have to decipher what was supposed to happen and then spend minutes or hours piecing together their reproduction. Usually, they can’t get it right, so they have to ask for clarification. This back-and-forth process takes lots of energy and wastes everyone’s time. Instead, it’s better to provide an example app from the beginning. At the end of the day, would you rather maintainers spend their time making example apps or fixing issues?
-
-
css-tricks.com css-tricks.com
-
always use real <label for="correct_input"> elements. Just that alone is a UX consideration all too many forms fail on
-
-
trailblazer.to trailblazer.to
-
In production, you will never trigger one specific callback or a particular validation, only. Your application will run all code required to create a Song object, for instance. In Trailblazer, this means running the Song::Create operation, and testing that very operation with all its side-effects.
-
There’s no need to test controllers, models, service objects, etc. in isolation
Tags
- testing: avoid unnecessarily testing things in too much isolation, in a different way than the code is actually used (should match production)
- unnecessary
- isolation (programming)
- testing: test the side effects
- testing: tests should resemble the way your software is used
- testing: avoid testing implementation details
Annotators
URL
-
- Feb 2021
-
www.metacritic.com www.metacritic.comWarsaw1
-
Difficult enough to prove a worthy challenge, with an over-complexity that might have benefitted from a little self-restraint.
overly complex = unnecessarily complicated
-
-
trailblazer.to trailblazer.to
-
They help streamlining the control flow, and take away control code while providing you with an incredibly cool developer experience.
-
-
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
-
Why is all this interaction code better? Two reasons: One, you can reuse the FindAccount interaction in other places, like your API controller or a Resque task. And two, if you want to change how accounts are found, you only have to change one place.
Pretty weak arguments though...
- We could just as easily used a plain object or module to extract this for easy reuse and having it in only one place (avoiding duplication).
-
-
copyheart.org copyheart.org
-
Instead of trying to educate everyone on the complexities of copyright law, we’d rather make our intentions clear with this simple statement:
-
-
stackoverflow.com stackoverflow.com
-
I have checked the following close stackoverflow sources : Relation passed to #or must be structurally compatible. Incompatible values: [:references]
referencing similar questions so it won't be marked as duplicate
-
- Dec 2020
-
github.com github.com
-
sapper.svelte.dev sapper.svelte.dev
-
When Sapper renders a page on the server, it will attempt to serialize the resolved value (using devalue) and include it on the page, so that the client doesn't also need to call preload upon initialization.
-
- Nov 2020
-
blog.hubspot.com blog.hubspot.com
-
This scenario demonstrates one drawback of CSS: With all the style rules that need to be applied to multiple elements on multiple pages, things can get pretty redundant. And redundancy can eat up your time and cause friction whenever you need to change a color, font, or any other style aspect across your site.
-
-
developer.mozilla.org developer.mozilla.org
-
Custom properties allow a value to be stored in one place, then referenced in multiple other places.
-
-
github.com github.com
-
Microbundle also outputs a modern bundle specially designed to work in all modern browsers. This bundle preserves most modern JS features when compiling your code, but ensures the result runs in 90% of web browsers without needing to be transpiled. Specifically, it uses preset-modules to target the set of browsers that support <script type="module"> - that allows syntax like async/await, tagged templates, arrow functions, destructured and rest parameters, etc. The result is generally smaller and faster to execute than the esm bundle
-
-
github.com github.com
-
@monkeythedev I am curious how do you "organize" your work - You forked https://github.com/hperrin/svelte-material-ui and https://github.com/hperrin/svelte-material-ui is not very active. Do you plan an independent project ? I hope the original author would return at some times, if not, i'll see
-
-
material.io material.io
-
Trapping focus correctly for a modal dialog requires a complex set of events and interaction patterns that we feel is best not duplicated within the logic of this component.
-
-
laniewski.me laniewski.me
-
It is important to notice that if you are planning on making your application a PWA, you don’t have to rewrite all the logic.
-
- Oct 2020
-
docs.gitlab.com docs.gitlab.com
-
By using deploy keys, you don’t have to set up a fake user account.
-
-
-
Take responsibility for your outgoing network traffic If you install software that interacts with other sites over the network, you should be aware how it works and what kind of traffic it generates. If it has the potential to make thousands of requests to other sites, make sure it uses an HTTP cache to prevent inflicting abuse on other sites.
-
-
-
-
It is not appropriate to use these document types for live content. These are made available only for download, to support local use in development, evaluation, and validation tools. Using these versions directly from the W3C server could cause automatic blockage, preventing them from loading. If it is necessary to use schemata in content, follow guidelines to avoid excessive DTD traffic. For instance, use caching proxies to avoid fetching the schema each time it is used, or ensure software uses a local cache, such as with XML catalogs.
-
-
github.com github.com
-
Instead of calling prepare twice to get value from data.
Tags
Annotators
URL
-
-
medium.com medium.com
-
but the design pattern is so simple that it takes hardly any effort to implement it on any existing reducer, so I rejected abstraction for abstraction's sake.
-
-
final-form.org final-form.org
-
Adding checks for bracket[3] syntax as opposed to dot.3 syntax adds a lot of complexity, and has consciously been avoided.
-
-
ponyfoo.com ponyfoo.comPony Foo1
-
Sometimes we can’t implement a solution that’s fully spec-compliant, and in those cases using a polyfill might be the wrong answer. A polyfill would translate into telling the rest of the codebase that it’s okay to use the feature, that it’ll work just like in modern browsers, but it might not in edge cases.
-
-
humanwhocodes.com humanwhocodes.com
-
Once again, this isn’t good or bad, it’s just the most efficient way to create something that is similar to something else
-
-
-
One of the primary tasks of engineers is to minimize complexity. JSX changes such a fundamental part (syntax and semantics of the language) that the complexity bubbles up to everything it touches. Pretty much every pipeline tool I've had to work with has become far more complex than necessary because of JSX. It affects AST parsers, it affects linters, it affects code coverage, it affects build systems. That tons and tons of additional code that I now need to wade through and mentally parse and ignore whenever I need to debug or want to contribute to a library that adds JSX support.
Tags
- can't keep entire system in your mind at once (software development) (scope too large)
- syntax
- too complicated
- the cost of changing something
- for-reaching consequences
- mental bandwidth
- engineers
- avoid complexity
- mentally filter/ignore
- engineering (general)
- semantics (of programming language)
- infectious problem
- high-cost changes
- complexity
- unintended consequence
- primary task/job/responsibility
- implementation complexity
- fundamental
Annotators
URL
-
-
github.com github.com
-
The reason why we don't just create a real DOM tree is that creating DOM nodes and reading the node properties is an expensive operation which is what we are trying to avoid.
-
-
leiss.ca leiss.ca
-
“Complexity cloaks Catastrophe”
-
-
github.com github.com
-
This proposal simplifies how React.createElement works and ultimately lets us remove the need for forwardRef.
-
-
reactjs.org reactjs.org
-
Note how we have to duplicate the code between these two lifecycle methods in class. This is because in many cases we want to perform the same side effect regardless of whether the component just mounted, or if it has been updated. Conceptually, we want it to happen after every render — but React class components don’t have a method like this. We could extract a separate method but we would still have to call it in two places.
-
-
github.com github.com
-
Transparent debugging: a <div> is just a div.
-
- Sep 2020
-
engineering.mixmax.com engineering.mixmax.com
-
many CDNs nowadays ultimately source from npm (before caching the JavaScript on their own edge servers). So you'll be guaranteed to have the same library version on the CDN as on npm
-
-
github.com github.com
-
There's no way to change style incapsulation method without patching the compiler, and this means maintaing a fork, which is not desirable.
-
-
github.com github.com
-
Lets not extend the framework with yet another syntax
-
-
-
Part of the functionality that is returned are event handlers. I'd like to avoid needing to manually copy the events over one by one so the hook implementation details are hidden.
-
-
-
To learn about canceling fetch requests, search the internet for
-
-
refactoring.guru refactoring.guru
-
Eliminating needless classes frees up operating memory on the computer—and bandwidth in your head.
-
-
github.com github.com
-
The alternative is to duplicate markup inline:
-
- Aug 2020
-
docs.gitlab.com docs.gitlab.com
-
Do not include the same information in multiple places. Link to a SSOT instead.
-
Having a knowledge base in any form that is separate from the documentation would be against the docs-first methodology because the content would overlap with the documentation.
-
New information that would be useful toward the future usage or troubleshooting of GitLab should not be written directly in a forum or other messaging system, but added to a docs MR and then referenced, as described above.
-
When you encounter new information not available in GitLab’s documentation (for example, when working on a support case or testing a feature), your first step should be to create a merge request (MR) to add this information to the docs. You can then share the MR in order to communicate this information.
-
If the answer to a question exists in documentation, share the link to the docs instead of rephrasing the information.
-
There is a temptation to summarize the information on another page. This will cause the information to live in two places. Instead, link to the SSOT and explain why it is important to consume the information
-
At GitLab, we have so many product changes in our monthly releases that we can’t afford to continuously update multiple types of information. If we have multiple types, the information will become outdated.
-
- Jul 2020
-
www.w3.org www.w3.org
-
RDFa is intended to solve the problem of marking up machine-readable data in HTML documents. RDFa provides a set of HTML attributes to augment visual data with machine-readable hints. Using RDFa, authors may turn their existing human-visible text and links into machine-readable data without repeating content.
-
-
about.gitlab.com about.gitlab.com
-
A simplified pricing and packaging (PnP) strategy serves customers in the optimal way per the industry best practice. More SKUs lead to a more complex PnP model as a company scales, which eventually causes huge confusion to customers.
-
-
rails.lighthouseapp.com rails.lighthouseapp.com
-
It would be nice if the tests weren't so implementation specific, but rather tested the essence of the functionality. I tried to make them less brittle but failed. To that end, re-writing all the tests in rspec would be (IMHO) a brilliant improvement and pave the way for better tests in the future and more flexibility in implementation.
-
- Jun 2020
-
edgeguides.rubyonrails.org edgeguides.rubyonrails.org
-
If you've found a problem in Ruby on Rails which is not a security risk, do a search on GitHub under Issues in case it has already been reported. If you are unable to find any open GitHub issues addressing the problem you found, your next step will be to open a new one.
-
-
github.com github.com
-
It's funny that in such a complex gem like this, there's only one open issue, exactly about what I came here to post.
-
- May 2020
-
en.wikipedia.org en.wikipedia.org
-
Because the conditional connectives thus complicate the formal reasoning about programs, they are better avoided.
-
-
docs.gitlab.com docs.gitlab.com
-
There are no plans to deprecate the REST API. To reduce the technical burden of supporting two APIs in parallel, they should share implementations as much as possible.
Tags
Annotators
URL
-
-
developers.google.com developers.google.com
-
A "tag" is a snippet of code that allows digital marketing teams to collect data, set cookies or integrate third-party content like social media widgets into a site.
This is a bad re-purposing of the word "tag", which already has specific meanings in computing.
Why do we need a new word for this? Why not just call it a "script" or "code snippet"?
-
-
blog.hubspot.com blog.hubspot.com
-
Starting your answer with a word commonly associated with equivocation automatically weakens your answers and makes you sound less sure of yourself.
-
- Apr 2020
-
-
One thing is certain when it comes to navigation trends, users and designers seem to be fed up with completely hidden styles and demand options that work in similar formats on desktops and mobile devices. This might be one of the reasons a vertical pattern is trending.
-
-
medium.com medium.com
-
Running the same code in the browser and on the server in order to avoid code duplication is a very different problem. It is simply a matter of good development practices to avoid code duplication. This however is not limited to isomorphic applications. A utility library such as Lodash is “universal”, but has nothing to do with isomorphism. Sharing code between environments does not give you an isomorphic application. What we’re referring to with Universal JavaScript is simply the fact that it is JavaScript code which is environment agnostic. It can run anywhere. In fact most JavaScript code will run fine on any JavaScript platform.
-
-
makandracards.com makandracards.com
-
What we actually want to do is to escape content if it is unsafe, but leave it unescaped if it is safe. To achieve this we can simply use SafeBuffer's concatenation behavior:
-
Our helper still returns a safe string, but correctly escapes content if it is unsafe. Note how much more flexible our group helper has become because it now works as expected with both safe and unsafe arguments. We can now leave it up to the caller whether to mark input as safe or not, and we no longer need to make any assumptions about the safeness of content.
-
-
falcon.readthedocs.io falcon.readthedocs.io
-
When it comes to building HTTP APIs, other frameworks weigh you down with tons of dependencies and unnecessary abstractions. Falcon cuts to the chase with a clean design that embraces HTTP and the REST architectural style.
-
-
english.stackexchange.com english.stackexchange.com
-
As you indicate, it will be misunderstood in some quarters, which might be a good reason for avoiding it.
-
-
en.wikipedia.org en.wikipedia.org
-
In 1999, "collateral damage" (German: Kollateralschaden) was named the German Un-Word of the Year by a jury of linguistic scholars. With this choice, it was criticized that the term had been used by NATO forces to describe civilian casualties during the Kosovo War, which the jury considered to be an inhuman euphemism.
-
the classic Orwellian arguments for finding this usage objectionable
-
it is jargon, and to the extent that people cannot decode it, it conceals what is actually going on;
-
- Mar 2020
-
matomo.org matomo.org
-
the privacy of your users is respected
-
The relationship is between the website owner (you) and the visitor, with no external sources looking in
-
-
matomo.org matomo.org
-
With Matomo, the philosophy around data ownership is simple, you own your data, no one else.
-
-
wordpress.org wordpress.org
-
Why is the changelog on a separate page and not here? The WordPress.org repository is just another place to download this plugin. I don’t want to maintain too many pages with the same content.
-
- Feb 2020
-
about.gitlab.com about.gitlab.com
-
As a result, there is a natural tendency for people to prefer private channels of communication. The intentions are good, as people are looking to reduce noise for others, but this can lead to the same problems as described elsewhere on this page
-
Avoid Private Messages When using Slack for work-related purposes, please avoid private messages.
-
-
about.gitlab.com about.gitlab.com
-
Use the simplest and most boring solution for a problem, and remember that “boring” should not be conflated with “bad” or “technical debt.” The speed of innovation for our organization and product is constrained by the total complexity we have added so far, so every little reduction in complexity helps. Don’t pick an interesting technology just to make your work more fun; using established, popular tech will ensure a more stable and more familiar experience for you and other contributors.
-
- Dec 2019
-
-
It's confusing whether one should put things in gemspec development_dependencies or in Gemfile or in both.
Duplication is bad since the lists could get out of sync. And the gemspec's development_dependencies should be a complete list. Therefore, my opinion is that that should be the canonical list and therefore the only list.
Actually, what good is gemspec's development_dependencies? A contributor should clone the repo, run bundle, and get the dev dependencies that way. Therefore development_dependencies is unneeded and you should only list them in Gemfile.
It is simpler to just use Gemfile, since it is a more familiar format. You can copy and paste content into it. For example, if you extract a gem out of an app, you may wan to copy/move some gems from app's Gemfile into new gem's Gemfile. It also generates a Gemfile.lock (which you shouldn't add to git).
-
- Nov 2019
-
hapgood.us hapgood.us
-
It’s not enough to check the stuff that is suspicious: if you apply your investigations selectively, you’ve already lost the battle.
This made me reflection on biases. If our research methodology is biased from the very beginning, then everything that comes after will also be biased.
-
-
github.com github.com
-
The chosen approach pushes a lot of complexity out of the core. As a result it might take more code to achieve certain functionalities. This is the price of flexibility. And that's the primary design goal of Reactabular.
-
-
kentcdodds.com kentcdodds.com
-
it doesn't even render in-file components. For example, the <Fade /> component we have above is an implementation detail of the <HiddenMessage /> component, but because we're shallow rendering <Fade /> isn't rendered so changes to that component could break our application but not our test. That's a major issue in my mind and is evidence to me that we're testing implementation details.
-
The reason this kind of test fails those considerations is because it's testing irrelevant implementation details. The user doesn't care one bit what things are called. In fact, that test doesn't even verify that the message is hidden properly when the show state is false or shown when the show state is true. So not only does the test not do a great job keeping us safe from breakages, it's also flakey and doesn't actually test the reason the component exists in the first place.
-
I could rename toggle to handleButtonClick (and update the corresponding onClick reference). My test breaks despite this being a refactor.
-
I could mistakenly set onClick of the button to this.tgogle instead of this.toggle. My test continues to work, but my component is broken.
-
Will this test break when there's a mistake that would break the component in production?Will this test continue to work when there's a fully backward compatible refactor of the component?
-
-
kentcdodds.com kentcdodds.com
-
-
Why is testing implementation details bad?There are two distinct reasons that it's important to avoid testing implementation details. Tests which test implementation details:Can break when you refactor application code. False negativesMay not fail when you break application code. False positives
-
-
kentcdodds.com kentcdodds.com
-
But far too often, I see tests which are testing implementation details (read this before continuing if you haven't already). When you do this, you introduce a third user. The developer user and the end user are really all that matters for this component. So long as it serves those two, then it has a reason to exist. And when you're maintaining the component you need to keep those two users in mind to make sure that if you break the contract with them, you do something to handle that change.But as soon as you start testing things which your developer user and end user don't know or care about (implementation details), you add a third testing user, you're now having to keep that third user in your head and make sure you account for changes that affect the testing user as well.
-
-
testing-library.com testing-library.com
-
You want to write maintainable tests for your React components. As a part of this goal, you want your tests to avoid including implementation details of your components and rather focus on making your tests give you the confidence for which they are intended. As part of this, you want your testbase to be maintainable in the long run so refactors of your components (changes to implementation but not functionality) don't break your tests and slow you and your team down.
-
-
about.gitlab.com about.gitlab.com
-
many organizations end up with messy workflows, or overly complex ones.
-
- Sep 2013
-
rhetoric.eserver.org rhetoric.eserver.org
-
It may be said that every individual man and all men in common aim at a certain end which determines what they choose and what they avoid.
What is left out is as important to shaping the argument and what is chosen.
Tags
Annotators
URL
-