attrs
heroicons
Our great sponsors
attrs | heroicons | |
---|---|---|
11 | 78 | |
5,065 | 20,610 | |
0.7% | 1.4% | |
9.2 | 7.2 | |
8 days ago | 27 days ago | |
Python | JavaScript | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
attrs
-
Litestar 2.0
Full support for validation and serialisation of attrs classes and msgspec Structs. Where previously only Pydantic models and types where supported, you can now mix and match any of these three libraries. In addition to this, adding support for another modelling library has been greatly simplified with the new plugin architecture
- Ask HN: How can I get better at writing production-level Python?
-
Starlite updates March '22 | 2.0 is coming
Pydantic is by far not the only library of its kind, with prominent members of the same class being attrs, cattrs or even plain dataclasses for some use cases.
-
Data Classification: Does Python still have a need for class without dataclass?
Anything requiring e.g. setattr, getattr, delattr? Without looking far,
https://github.com/python-attrs/attrs/blob/main/src/attr/_ma...
- What new Python features are the most useful for you?
- Why you should use Data Classes in Python
-
Python Built-In Functions to Know
I was looking for an example of using locals() to "fill a data class from kwargs" or something similar to that. The example here doesn't use locals().
That aside, I generally wouldn't use the kwargs approach shown in this example either. I'd use [dataclasses](https://docs.python.org/3/library/dataclasses.html ) or [attrs](https://www.attrs.org/) instead.
-
Building a Micro Business: What Services I Pay For
hynek: developer of attrs
-
Soap and REST at Odds (2017)
I continue to be surprised how easy it can be to consume a SOAP API with the right client libraries. Such as https://docs.python-zeep.org/en/master/ for Python. Now that's not to say it will always work, you can design a terrible API with any mechanism, no SOAP or REST client will help you if the other end has desided to succumb to madness and done something like turn their entire API into just "two endpoints" and driven by the payload content you post to the inbound endpoint, and you have to sit there polling the outbound endpoint with the inbound endpoints response ID because to find out what the eventual response is...
But horror story aside, consuming a decent SOAP endpoint with a good client library can be practically magical.
Between attrs (https://www.attrs.org/), cattrs (https://cattrs.readthedocs.io/), and the aforementioned zeep soap client I've got a serialisation pipeline from soap endpoint into an attrs dataclass with type hints and basic type validation down to a snippet so small it fits right here (type hints removed to minimise size).
from zeep import helpers
-
PEP 661 -- Sentinel Values
attrs has at least two.
heroicons
- Autopreenchimento de campos no FilamentPHP usando API
-
Discord Clone Using Next.js and Tailwind - Part 3: Channel List
We start with the toggle button. We want icons for this that we get from heroicons. Let’s create a new file in the ChannelList folder called Icons.tsx and paste the code for the icons here to have a solid separation:
-
Free Icons for your reactjs and web applications
7. Heroicons
-
Create responsive navbar with React and Tailwind using the same markdown
Since we are on the mobile view we want to add a hamburger menu to toggle the links visibility. I am using heroicons. We use some basic react state to know whether or not the hambuger is open, and we conditionally render either the hamburger or an X.
-
Using Heroicons with TailwindCSS
Heroicons are SVG-based icons packaged by the creators of TailwindCSS. They come in two size variants, 20, which is suitable for small buttons and form elements, and a 24 size, that is useful for primary navigation buttons like call to action and hero sections. 24 size comes as solid and outline.
-
Complete Tutorial: React Admin Panel with refine and daisyUI
We have to install refine's support packages for React Table and React Hook Form. We are using Tailwind Heroicons for our icons, the Day.js library for time calculations and Recharts library to plot our charts for KPI data. So, run the following and we are good to go:
-
29 Websites For Free Icon Sets
heroicons - Beautiful hand-crafted SVG icons, by the makers of Tailwind CSS.
-
A simple theme switcher in React for Tailwind CSS
These depedencies provide unstyled accessible components from headless ui, icons from heroicons and common hooks with typescript support.
-
Creating an Image Upload Modal with Crop and Rotate Functionality in React
To get started with our image modal implementation, i'll assume you already have a React project set up. For UI i’m using Tailwind CSS. But you can use any UI library as your wish. For the image cropping and rotating functionality, we'll be utilizing the react-easy-crop library. This library provides a simple and intuitive way to crop and interact with images and videos within a React component. We will also use the heroicons and classnames libraries in our tutorial. To install all the libraries and their dependencies, open your terminal and navigate to your project's directory. Run the following command:
- Devs who have been laid off, how are you spending your time preparing for new roles?
What are some alternatives?
itsdangerous - Safely pass trusted data to untrusted environments and back.
react-icons - svg react icons of popular icon packs
transitions - A lightweight, object-oriented finite state machine implementation in Python with many extensions
Font-Awesome - The iconic SVG, font, and CSS toolkit
pluginbase - A simple but flexible plugin system for Python.
content - The file-based CMS for your Nuxt application, powered by Markdown and Vue components.
Pychievements - The Python Achievements Framework!
feather - Simply beautiful open-source icons
Throttler - 🔀⏳ Easy throttling with asyncio support
icons - Official open source SVG icon library for Bootstrap.
blinker - A fast Python in-process signal/event dispatching system.
Alpine.js - A rugged, minimal framework for composing JavaScript behavior in your markup.