Adding methods to built-in objects: it’s one of JavaScript’s most powerful features. It’s also a great way to offend the sensibilities of your colleagues. We all hear that it’s irresponsible, that it’s sloppy, that it’s flat-out bad practice and should be avoided.
I’m tired of this one-sided battle. In this talk, I’m going to push back against whatever blog post you read that told you that extending built-ins was unconditionally and universally bad. I’m gonna go all Howard Beale on your asses.
Slides from Ajax Experience 2009. In this session:
- Object creation patterns
- Code reuse patterns
- Functional patterns
- More on object creation
- Design patterns
Some example patterns: object creation with literals and constructos, prototypes, inheritance and other code reuse patterns, lazy definition, callbacks, singleton, factory, classical and prototypal inheritance, namespaces, chaining, modules, static methods, private and privileged members
For more information, see:
http://jspatterns.com
My column in the JavaScript Magazine (http://jsmag.com)
Blog: http://phpied.com
My JSConf.eu talk about next-gen JavaScript metaprogramming features, starting with ES5's new Object APIs and then focusing on the forthcoming Proxy object, approved for the next ECMA-262 Edition. This is beautiful work from Tom Van Cutsem and Mark Miller, with Andreas Gal helping on the implementation front -- proxies are already shipping in Firefox 4 betas.
In this presentation we will go over some of the new features of the modern JavaScript.
We will get a quick introduction of how to embrace the new features, how to navigate through them, and how not to get overwhelmed.
There will be some examples of the more useful features that you will want to understand and begin to adopt.
Slides from Ajax Experience 2009. In this session:
- Object creation patterns
- Code reuse patterns
- Functional patterns
- More on object creation
- Design patterns
Some example patterns: object creation with literals and constructos, prototypes, inheritance and other code reuse patterns, lazy definition, callbacks, singleton, factory, classical and prototypal inheritance, namespaces, chaining, modules, static methods, private and privileged members
For more information, see:
http://jspatterns.com
My column in the JavaScript Magazine (http://jsmag.com)
Blog: http://phpied.com
My JSConf.eu talk about next-gen JavaScript metaprogramming features, starting with ES5's new Object APIs and then focusing on the forthcoming Proxy object, approved for the next ECMA-262 Edition. This is beautiful work from Tom Van Cutsem and Mark Miller, with Andreas Gal helping on the implementation front -- proxies are already shipping in Firefox 4 betas.
In this presentation we will go over some of the new features of the modern JavaScript.
We will get a quick introduction of how to embrace the new features, how to navigate through them, and how not to get overwhelmed.
There will be some examples of the more useful features that you will want to understand and begin to adopt.
Ten useful JavaScript tips & best practicesAnkit Rastogi
In this presentation there are ten useful JavaScript techniques which can be included in your application easily with less friction along with some AngularJs tips and best practices as a bonus. These tips and best practices are accompanied by examples & will cover script loading, design pattern, performance optimization and other areas.
Since best practices are very subjective topics, proper benchmarking needs to be done.
JavaScript has some stunning features like Closures, Prototype etc. which can help to improve the readability and maintainability of the code. However, it is not easy for inexperienced developer to consume and apply those features in day to day coding. The purpose of the presentation ‘Advanced JavaScript’ is to help a reader easily understand the concept and implementation of some advanced JavaScript features.
The Guava project contains several of Google’s core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth. There will be the slides presenting most useful and interesting features of Guava (v.12) that makes stuff simpler, better and code cleaner. We will cover most of the com.google.common.base.* classes and basic use of functions in collection and Google collections and few other features that are part of Guava and I find them very useful. Some of you will think that there is an overlap with Apache commons – and it’s true, but Guava is built with expectation that there is a Function and a Predicate class as well as various builders which makes it really cool and simple for many use cases.
Love it or hate it, JavaScript is playing an increasingly important role in the next generation of web and mobile apps. As code continues to move from the server to the client, JavaScript is being used to do more than simple HTML manipulation. Be prepared for this transition and make sure the JavaScript you write is optimized and ready to perform on desktops and devices! In this session, you will learn ten practical tips that you can use today to write faster, more maintainable, memory friendly JavaScript.
Google Guava - Core libraries for Java & AndroidJordi Gerona
Talk at GDG DevFest Barcelona 2013.
The Guava project contains several of Google's core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth.
The PPTs from one of the event of iWillStudy.com - a leading start-up in the education space in India. This PPT is being used at an event where they taught iPhone programming and applications development.
It's happened to all of us: we ran away from some conversation or library because it kept on using those "weird" phrases. You know, like "type classes", "semigroups", "monoids", "applicatives". Yikes! They all seem so academic, so pointlessly detached from real-world problems. But then again, given how frequently we run into them in functional programming, are they REALLY irrelevant, or do they have real-world applications? This talk will go beyond giving you raw definitions of these terms, and show you real-world motivations behind the concepts. By attending, you'll be able to keep your skills relevant to an ever-changing industry, confuse your significant other ("You know, honey, a monad is just a monoid in the category of endofunctors!"), and sound extra smart on the next job interview!
The things we don't see – stories of Software, Scala and AkkaKonrad Malawski
Opening keynote for Scalapeno, Tel Aviv 2016.
The talk focuses and explains the things we don't often see explicitly and/or don't notice when doing our daily work, yet make up a large part of the ecosystem and maturity of the ecoststem as a whole. We also dive into some of the more confusing bits around using the same word about different things in software
Ten useful JavaScript tips & best practicesAnkit Rastogi
In this presentation there are ten useful JavaScript techniques which can be included in your application easily with less friction along with some AngularJs tips and best practices as a bonus. These tips and best practices are accompanied by examples & will cover script loading, design pattern, performance optimization and other areas.
Since best practices are very subjective topics, proper benchmarking needs to be done.
JavaScript has some stunning features like Closures, Prototype etc. which can help to improve the readability and maintainability of the code. However, it is not easy for inexperienced developer to consume and apply those features in day to day coding. The purpose of the presentation ‘Advanced JavaScript’ is to help a reader easily understand the concept and implementation of some advanced JavaScript features.
The Guava project contains several of Google’s core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth. There will be the slides presenting most useful and interesting features of Guava (v.12) that makes stuff simpler, better and code cleaner. We will cover most of the com.google.common.base.* classes and basic use of functions in collection and Google collections and few other features that are part of Guava and I find them very useful. Some of you will think that there is an overlap with Apache commons – and it’s true, but Guava is built with expectation that there is a Function and a Predicate class as well as various builders which makes it really cool and simple for many use cases.
Love it or hate it, JavaScript is playing an increasingly important role in the next generation of web and mobile apps. As code continues to move from the server to the client, JavaScript is being used to do more than simple HTML manipulation. Be prepared for this transition and make sure the JavaScript you write is optimized and ready to perform on desktops and devices! In this session, you will learn ten practical tips that you can use today to write faster, more maintainable, memory friendly JavaScript.
Google Guava - Core libraries for Java & AndroidJordi Gerona
Talk at GDG DevFest Barcelona 2013.
The Guava project contains several of Google's core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth.
The PPTs from one of the event of iWillStudy.com - a leading start-up in the education space in India. This PPT is being used at an event where they taught iPhone programming and applications development.
It's happened to all of us: we ran away from some conversation or library because it kept on using those "weird" phrases. You know, like "type classes", "semigroups", "monoids", "applicatives". Yikes! They all seem so academic, so pointlessly detached from real-world problems. But then again, given how frequently we run into them in functional programming, are they REALLY irrelevant, or do they have real-world applications? This talk will go beyond giving you raw definitions of these terms, and show you real-world motivations behind the concepts. By attending, you'll be able to keep your skills relevant to an ever-changing industry, confuse your significant other ("You know, honey, a monad is just a monoid in the category of endofunctors!"), and sound extra smart on the next job interview!
The things we don't see – stories of Software, Scala and AkkaKonrad Malawski
Opening keynote for Scalapeno, Tel Aviv 2016.
The talk focuses and explains the things we don't often see explicitly and/or don't notice when doing our daily work, yet make up a large part of the ecosystem and maturity of the ecoststem as a whole. We also dive into some of the more confusing bits around using the same word about different things in software
Concurrent programming with Celluloid (MWRC 2012)tarcieri
Threads versus events: which should you choose? How about both? In this talk you'll learn about the Celluloid concurrency framework, which combines OOP and the Actor Model to give you concurrent Ruby objects. You'll also learn about how Celluloid lets you combine blocking I/O and asynchronous evented I/O, offering you all the benefits of EventMachine without the restrictions of a single event loop. The talk will also provide a brief introduction to DCell, a distributed extension to Celluloid.
Writing code as an individual and writing code as part of the team are two very different things. Learn the tips and tricks for writing JavaScript code as part of the team so that your code will continue to work for years to come.
Slides from my talk "Node.js Patterns for Discerning Developers" given at Pittsburgh TechFest 2013. This talk detailed common design pattern for Node.js, as well as common anti-patterns to avoid.
Examples: https://gist.github.com/aditya01933/c6a867e981110885369f06c5a4103644
1. 3 pillars of ruby.
2. Classes and objects.
3. Inheritance - diving deep
4. Meta programming and reflection - diving deep.
5. Power of method missing.
6. Mixins and ducktyping
7. Super - diving deep
8. Yield
9. Closure
10. Block, proc and lambda
11. More meta programming(examples).
12. Ruby open classes.
Similar to Everything is Permitted: Extending Built-ins (20)
Godwin's Law for JavaScript: as people discuss a proposed extension to JavaScript syntax, the likelihood of someone saying "Stop trying to turn JavaScript into Java!" approaches 1.
For years I've tried to understand this perspective. Why are there so many people out there for whom present-day JavaScript is Good Enough™? What crucial aspect of JavaScript's identity are they trying to defend? Why do they get so scared when someone suggests new syntax? Can we figure out how to evolve the language without incurring the wrath of their pitchforks and/or torches?
None of us would be very good developers if we never had arguments about The Best Way to Do Things. But I've had enough silly arguments about tabs-versus-spaces to last me the rest of my life. When should we stop arguing and start writing code? I'll share specific tactics for keeping code arguments evidence-based, respectful, and drama-free.
Given at Refresh Austin on September 11, 2012.
The rules of diplomatic debate apply just as much to code as they do to anything else. I'm going to try to identify what separates good debate from bad debate, and share specific tactics for keeping these arguments evidence-based, respectful, and drama-free.
Is your web app drowning in a sea of JavaScript? Has your client-side codebase grown from "a snippet here and there" to "more JavaScript than HTML"? Do you find yourself writing one-off snippets instead of generalized components? You're not the only one. Learn about a handful of strategies you can use to keep your JavaScript codebase lean, modular, and flexible. We'll cover all the major pain points — MVC, templates, persisting state, namespacing, graceful error handling, client/server communication, and separation of concerns. And we'll cover how to do all this incrementally so that you don't have to redo everything from scratch.
We know that the Internet can be used to donate to political candidates. Or make fun of them. But, with a little help from citizens, it can also make government work better. First, we’ll look at a handful of sites that aggregate government data and present it in useful ways. Then we’ll explore the process of distilling government data dumps and APIs to build our own sites.
Transcript: Selling digital books in 2024: Insights from industry leaders - T...BookNet Canada
The publishing industry has been selling digital audiobooks and ebooks for over a decade and has found its groove. What’s changed? What has stayed the same? Where do we go from here? Join a group of leading sales peers from across the industry for a conversation about the lessons learned since the popularization of digital books, best practices, digital book supply chain management, and more.
Link to video recording: https://bnctechforum.ca/sessions/selling-digital-books-in-2024-insights-from-industry-leaders/
Presented by BookNet Canada on May 28, 2024, with support from the Department of Canadian Heritage.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Search and Society: Reimagining Information Access for Radical FuturesBhaskar Mitra
The field of Information retrieval (IR) is currently undergoing a transformative shift, at least partly due to the emerging applications of generative AI to information access. In this talk, we will deliberate on the sociotechnical implications of generative AI for information access. We will argue that there is both a critical necessity and an exciting opportunity for the IR community to re-center our research agendas on societal needs while dismantling the artificial separation between the work on fairness, accountability, transparency, and ethics in IR and the rest of IR research. Instead of adopting a reactionary strategy of trying to mitigate potential social harms from emerging technologies, the community should aim to proactively set the research agenda for the kinds of systems we should build inspired by diverse explicitly stated sociotechnical imaginaries. The sociotechnical imaginaries that underpin the design and development of information access technologies needs to be explicitly articulated, and we need to develop theories of change in context of these diverse perspectives. Our guiding future imaginaries must be informed by other academic fields, such as democratic theory and critical theory, and should be co-developed with social science scholars, legal scholars, civil rights and social justice activists, and artists, among others.
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...James Anderson
Effective Application Security in Software Delivery lifecycle using Deployment Firewall and DBOM
The modern software delivery process (or the CI/CD process) includes many tools, distributed teams, open-source code, and cloud platforms. Constant focus on speed to release software to market, along with the traditional slow and manual security checks has caused gaps in continuous security as an important piece in the software supply chain. Today organizations feel more susceptible to external and internal cyber threats due to the vast attack surface in their applications supply chain and the lack of end-to-end governance and risk management.
The software team must secure its software delivery process to avoid vulnerability and security breaches. This needs to be achieved with existing tool chains and without extensive rework of the delivery processes. This talk will present strategies and techniques for providing visibility into the true risk of the existing vulnerabilities, preventing the introduction of security issues in the software, resolving vulnerabilities in production environments quickly, and capturing the deployment bill of materials (DBOM).
Speakers:
Bob Boule
Robert Boule is a technology enthusiast with PASSION for technology and making things work along with a knack for helping others understand how things work. He comes with around 20 years of solution engineering experience in application security, software continuous delivery, and SaaS platforms. He is known for his dynamic presentations in CI/CD and application security integrated in software delivery lifecycle.
Gopinath Rebala
Gopinath Rebala is the CTO of OpsMx, where he has overall responsibility for the machine learning and data processing architectures for Secure Software Delivery. Gopi also has a strong connection with our customers, leading design and architecture for strategic implementations. Gopi is a frequent speaker and well-known leader in continuous delivery and integrating security into software delivery.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
"Impact of front-end architecture on development cost", Viktor TurskyiFwdays
I have heard many times that architecture is not important for the front-end. Also, many times I have seen how developers implement features on the front-end just following the standard rules for a framework and think that this is enough to successfully launch the project, and then the project fails. How to prevent this and what approach to choose? I have launched dozens of complex projects and during the talk we will analyze which approaches have worked for me and which have not.
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Jeffrey Haguewood
Sidekick Solutions uses Bonterra Impact Management (fka Social Solutions Apricot) and automation solutions to integrate data for business workflows.
We believe integration and automation are essential to user experience and the promise of efficient work through technology. Automation is the critical ingredient to realizing that full vision. We develop integration products and services for Bonterra Case Management software to support the deployment of automations for a variety of use cases.
This video focuses on the notifications, alerts, and approval requests using Slack for Bonterra Impact Management. The solutions covered in this webinar can also be deployed for Microsoft Teams.
Interested in deploying notification automations for Bonterra Impact Management? Contact us at sales@sidekicksolutionsllc.com to discuss next steps.
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
3. “ There’s a whole lot of know-nothing advocacy
that’s still happening in the JS/webdev/design
world these days, and it annoys me to no end.
I’m not sure how our community got so religious
and fact-disoriented, but it has got to stop.”
Alex Russell
4. “If you use this book as a guide, by all means
leave the road when you wish. That is precisely
the use of a road: to reach individually chosen
points of departure. By all means break the
rules, and break them beautifully, deliberately
and well. That is one of the ends for which they
exist.”
Robert Bringhurst,
The Elements of Typographic Style
5. “Break any of these rules sooner than say
anything outright barbarous.”
George Orwell,
“Politics and the English Language”
8. @DonaldGlover
Donald Glover
Fuck what you heard, SHORTS ARE
DOPE. Just wear them right. Not mid leg
like you’re at a fuckin Creed concert.
30 Jul via Echofon
44. “I only re-open a class after I’ve tried every other
option like subclassing, wrapping, etc. If nothing else
works or is too much effort for the modification, then
I document the hell out of my modification and try
desperately to localize the change so that it doesn't
hurt anyone else.”
Zed Shaw,
“The Chainsaw Infanticide Logger Manuever”
http://is.gd/chainsaw_infanticide
45. “Don't slip a concrete dildo into someone's box of Fruit
Loops. They won't be happy with your Morning
Breakfast Surprise. Put the concrete dildo in a
clearly labeled box, with instructions. Then when
someone encounters a problem (‘Hey, something is
screwing me here. Maybe it's the concrete dildo?’) at
least they know to ask.”
The Higgs Bozo
http://is.gd/concrete_dildo
46. “In my mind, in Ruby < 2.0, there’s a category of library
which is ‘provide a number of useful core
extensions.’ The three major ones are ActiveSupport,
Extlib and Facets. In general, applications need to
choose one, but not more of these libraries to avoid
conflicts.”
Yehuda Katz
http://is.gd/cQar9O
48. Make it obvious when you’re defining core extensions.
module SomeLibrary
module CoreExtensions
module Object
def foo
# ...
end
end
end
end
class Object
include SomeLibrary::CoreExtensions::Object
end
49. Make core extensions as atomic as possible.
require 'active_support/core_ext/numeric/bytes'
3.megabytes
#=> 3145728
3.days.ago
# NoMethodError: undefined method `days' for 3:Fixnum
50. If you must monkey-patch, do so seamlessly.
Don’t break the old method’s contract.
class Array
alias_method :foo_original :foo
def foo(arg)
puts "Adding advice to the 'foo' method"
foo_original(arg)
end
end
53. Libraries I require will o en decide for themselves
which core extensions will be used.
{}.blank?
# NoMethodError: undefined method `blank?' for {}:Hash
require 'rails'
{}.blank?
#=> true
57. ES5 to the rescue?
Object.defineProperty(Object.prototype, 'extend',
{
writable: true,
configurable: true,
enumerable: false,
value: function() {
for (var i = 0, len = arguments.length, source; i < len; i++) {
source = arguments[i];
for (var property in source) {
if (source.hasOwnProperty(property))
this[property] = source[property];
}
}
}
}
);
58. var whiteHouse = { washington: 'adams' };
whiteHouse.extend({ adams: 'jefferson' });
for (var president in whiteHouse)
console.log(president);
//=> washington, adams
59.
60. But wait…
var whiteHouse = { extend: 'adams' };
whiteHouse.extend({ adams: 'jefferson' });
// TypeError: Property 'extend' of object #<Object>
// is not a function
68. var time = require('time');
var date = new Date();
date.setTimeZone('America/Chicago');
console.log(date.toString());
console.log(date.getTimezone());
console.log(date.getTimezoneAbbr());
Output:
Tue Apr 26 2011 02:45:21 GMT-0500 (CDT)
America/Chicago
CDT
70. We’ll be needing ES5 polyfills
“A polyfill … is a piece of code (or plugin) that
provides the technology that you, the
developer, expect the browser to provide
natively.”
Remy Sharp
http://remysharp.com/2010/10/08/what-is-a-polyfill/
71. if (!Object.keys) {
Object.keys = function(object) {
if (object !== Object(object))
throw new TypeError('Object.keys called on non-object');
var results = [];
for (var property in object) {
if (object.hasOwnProperty(property))
results.push(property);
}
return results;
};
}
72. if (!Function.prototype.bind) {
Function.prototype.bind = function(object) {
var slice = Array.prototype.slice,
args = slice.call(arguments, 1),
self = this;
var nop = function() {};
var bound = function() {
return self.apply(
this instanceof nop ? this : (object || {}),
args.concat(slice.call(arguments))
);
};
nop.prototype = self.prototype;
bound.prototype = new nop();
return bound;
};
}
77. “[W]e present classboxes, a module system for object-
oriented languages that allows method addition and
replacement. Moreover, the changes made by a
classbox are only visible to that classbox (or
classboxes that import it), a feature we call local
rebinding.”
So ware Composition Group,
University of Bern
http://scg.unibe.ch/research/classboxes
78. A classbox-like system called “refinements”
has been proposed for Ruby 2.0.
module TimeExtensions
refine Numeric do
def minutes; self * 60; end
end
end
2.minutes #=> NoMethodError
using TimeExtensions
2.minutes #=> 120