IT |
気になる、記になる… |
Apple、「iPhone 15」シリーズではProモデルの値上げを検討か |
https://taisy0.com/2023/07/24/174422.html
|
apple |
2023-07-24 12:59:45 |
IT |
気になる、記になる… |
PITAKA、AirTagを内蔵出来る防風ライター「PitaTag for Lighter」を発表 |
https://taisy0.com/2023/07/24/174417.html
|
pitatag |
2023-07-24 12:50:07 |
IT |
気になる、記になる… |
新型「Apple Watch Ultra」は現行モデルより軽くなる?? |
https://taisy0.com/2023/07/24/174414.html
|
apple |
2023-07-24 12:27:39 |
IT |
気になる、記になる… |
Spotify、欧米などで月額料金を値上げ ー 日本は対象外 |
https://taisy0.com/2023/07/24/174406.html
|
premium |
2023-07-24 12:07:35 |
IT |
InfoQ |
Implementing Application Level Encryption at Scale: Insights from Atlassian’s Use of AWS and Cryptor |
https://www.infoq.com/news/2023/07/atlassian-encryption-at-scale/?utm_campaign=infoq_content&utm_source=infoq&utm_medium=feed&utm_term=global
|
Implementing Application Level Encryption at Scale Insights from Atlassian s Use of AWS and CryptorAtlassian recently published how it performs Application Level Encryption at scale on AWS while utilising high cache hit rates and maintaining low costs Atlassian s solution runs over instances and manages over KMS keys It performs over billion decryptions and million encryptions daily costing per month versus a potential per month using a naive solution By Eran Stiller |
2023-07-24 12:30:00 |
Docker |
dockerタグが付けられた新着投稿 - Qiita |
DockerComposeを理解してみる |
https://qiita.com/ponponnsan/items/f9bb76b73be1df9fce0b
|
dockercompose |
2023-07-24 21:48:51 |
Docker |
dockerタグが付けられた新着投稿 - Qiita |
DockerでMariaDBを構築する |
https://qiita.com/engishoma/items/7eabeacf98562440bf52
|
kercomposeymldbdockerfi |
2023-07-24 21:19:45 |
Docker |
dockerタグが付けられた新着投稿 - Qiita |
Whisper を Docker 化してみた |
https://qiita.com/hidakakombu/items/0e12857c52d7d4f84b92
|
docker |
2023-07-24 21:06:30 |
Ruby |
Railsタグが付けられた新着投稿 - Qiita |
【Rails7/ActionCable】「ArgumentError - wrong number of arguments (given 1, expected 2)」に対するエラー対処(備忘録) |
https://qiita.com/gon0821/items/60fd638b23483adfcf12
|
actioncable |
2023-07-24 21:40:16 |
技術ブログ |
Developers.IO |
Amazon EMR: Spark を使用してクラスターを起動し、Amazon S3 バケットに格納されたPySparkスクリプトを実行してみた |
https://dev.classmethod.jp/articles/amazon-emr-spark-s3-pyspark/
|
amazon |
2023-07-24 12:43:09 |
海外TECH |
DEV Community |
Creating interactive UIs with Motion Layout using Jetpack Compose |
https://dev.to/mindfulengineering/creating-interactive-uis-with-motion-layout-using-jetpack-compose-4o0b
|
Creating interactive UIs with Motion Layout using Jetpack ComposeAfter going through this blog you ll achieve this kind of polished animation using MotionLayout Let s take baby steps and kick start with the Intro IntroductionAs an Android developer you might have encountered the need for layout animation and sometimes even morphing style layout animation That s where MotionLayout comes into the picture It fills the chasm between layout transitions and complex motion handling offering a diversity of features that lie between the capabilities of the property animation framework While MotionLayout has been around for some time in XML view it s fairly new in Jetpack Compose and is still maturing In this comprehensive guide we ll explore MotionLayout in Jetpack Compose with an example of Collapsing toolbar Prior to the MotionLayout Collapsing Toolbar has always been an intriguing subject in Android I believe you are well acquainted with how the implementation of the Collapsing toolbar with somewhat knotty animations was prolonged and a bit monotonous with the old XML based view system We ll focus on how we can achieve such complex Collapsing effects using MotionLayout in Jetpack compose Some common motion terminologyMotionLayout ーA MotionLayout API for the Old view system MotionCompose ーA MotionLayout API for Jetpack Compose MotionScene ーA file that defines the various Constraint Sets Transitions and Keyframes for a MotionLayout animation ConstraintSet ーA set of constraints that define the initial and final layout states along with any intermediate states for a MotionLayout Transition The animation sequence that occurs between two or more Constraint Sets in a MotionLayout KeyAttribute A property of a view that can be animated during a MotionLayout transition such as its position size or alpha value In this blog we ll learn about how to incorporate MotionCompose in the world of Jetpack Compose In the mists of time before ComposeFirstly a quick detour In the XML based view system We were creating collapsing app bars toolbars using the AppBarLayout and CollapsingToolbarLayout while keeping CoordinatorLayout as a parent layout The MotionLayout XML file contains information about the transitions and animations for the child views How it goes with ComposeWe can achieve the same in Jetpack Compose and nearly everything is entirely customizable and easy to implement Here it s implemented using a dedicated Composable function called MotionLayout The MotionLayout Composable is added as a child element to a parent layout Composable and the child views are added as direct children of the MotionLayout Composable The transitions and animations are defined using a MotionScene object which is created programmatically in Kotlin Why do you need MotionLayout Visual illustrations are very important when it comes to condensing information down so that the user does not feel overwhelmed while they are surfing through your app The animation works seamlessly regardless of the presence of a notch hardware navigation etc or the lack thereof Now you do not need MotionLayout to achieve this but it offers a neat solution by allowing you to constrain the position of the view to align with the layout Sometimes we may need to animate numerous properties attributes of a composable depending on the keyframes of an animation or we might want to have a complex animation This is where MotionLayout really shines streamlining the whole process by defining ConstraintSets that tell how the layout UI would look at the starting point of the animation and how it would be like at the end and simply MotionLayout will animate through those sets Kicking offThis documentation is based on the compose constraint layout version Include the following dependency in the module level build gradle s dependencies section implementation androidx constraintlayout constraintlayout compose Logically we d need to use constraint layout dependency since MotionLayout is a subclass of a Constraint layout Let s have a look at the Compose counterpart and explore its distinctiveness from the traditional MotionLayout approach MotionLayout vs MotionComposeThe first disparity between MotionLayout and MotionCompose is that MotionLayout allows developers to define animations in XML On the other hand MotionCompose is a new animation library introduced with Jetpack Compose It provides a declarative way to create and control animations in Compose UI MotionCompose is designed to provide a similar level of control and flexibility as MotionLayout but in a more declarative and composable way Perks of MotionCompose over MotionLayout More flexibilityEasier to useThe simplified syntax for creating animationsEasy to modify animations at runtimeEmpowers the creation of animations that are highly responsive and interactive facilitating the seamless creation of captivating user experiences In summary both MotionLayout and MotionCompose are powerful tools for handling motion and animation in Android MotionLayout is better suited for complex animations with a large number of views and constraints while MotionCompose is more suited for creating smooth and fluid animations in a declarative and composable way But for the time being we ll refer to it as MotionLayout to avoid any confusion OverloadsThere are different types of MotionLayout functions available with different signatures Some function accepts MotionScene and another counterpart you can directly add a MotionScene string as content The MotionLayout has a powerful array of properties in its quiver the table below is a vital resource that would fix your confusion of selecting the right method Bear in mind that as the screen content grows it d become baffling so to make it easy and clean JSON would be preferable You can peruse the overload options presented below as per your use case Motion Signature ー ExperimentalMotionApi Composablefun MotionLayout start ConstraintSet end ConstraintSet transition androidx constraintlayout compose Transition null progress Float debug EnumSet lt MotionLayoutDebugFlags gt EnumSet of MotionLayoutDebugFlags NONE modifier Modifier Modifier optimizationLevel Int Optimizer OPTIMIZATION STANDARD crossinline content Composable MotionLayoutScope gt Unit Motion Signature ー ExperimentalMotionApi Composablefun MotionLayout motionScene MotionScene progress Float debug EnumSet lt MotionLayoutDebugFlags gt EnumSet of MotionLayoutDebugFlags NONE modifier Modifier Modifier optimizationLevel Int Optimizer OPTIMIZATION STANDARD crossinline content Composable MotionLayoutScope gt Unit Motion Signature ー ExperimentalMotionApi Composablefun MotionLayout motionScene MotionScene constraintSetName String null animationSpec AnimationSpec lt Float gt tween lt Float gt debug EnumSet lt MotionLayoutDebugFlags gt EnumSet of MotionLayoutDebugFlags NONE modifier Modifier Modifier optimizationLevel Int Optimizer OPTIMIZATION STANDARD noinline finishedAnimationListener gt Unit null crossinline content Composable MotionLayoutScope gt Unit Motion Signature ー ExperimentalMotionApi Composablefun MotionLayout start ConstraintSet end ConstraintSet transition androidx constraintlayout compose Transition null progress Float debug EnumSet lt MotionLayoutDebugFlags gt EnumSet of MotionLayoutDebugFlags NONE informationReceiver LayoutInformationReceiver null modifier Modifier Modifier optimizationLevel Int Optimizer OPTIMIZATION STANDARD crossinline content Composable MotionLayoutScope gt Unit The first overload is the most primitive one In the MotionLayout there are two states to animate One is starting state and another is the ending state Progress is used to determine the current state of the animation between the starting and ending states means current progress is at “start means progress has reached to “end means the current is in the middle of two etc MotionLayout for Compose takes onThe constraint set can be defined in ways MotionScenes Inside MotionLayout JSON approach Both approaches have their pros and cons Depiction of a MotionScene s procedure within the MotionLayoutWe can add a MotionScene string as content like this MotionLayout start ConstraintSet end ConstraintSet progress progress modifier Modifier The downside of employing this approach is that as the content grows it may become baffling Let s have a look at the example Composablefun MyMotionLayout val motionScene remember MotionScene MotionLayout modifier Modifier fillMaxSize motionScene motionScene Box modifier Modifier constrainAs box start linkTo parent start top linkTo parent top end linkTo parent end bottom linkTo parent bottom Add your UI elements here Define the start and end constraint sets motionScene constraints createConstraints R id box start ConstraintSet Define your start constraints here end ConstraintSet Define your end constraints here Define the motion animations motionScene transition createTransition R id box fromState R id start toState R id end Define your motion animations here JSON approachThis blog focuses primarily on this approach and you ll see an example of this approach in a few moments First off Create a JSON file for the MotionScene at res raw motion scene jsonThe structure of the file would be somewhat like this ConstraintSets start end Here the start contains all the constraints for the initial state of motion and the end includes constraints for the final state Now we have to incorporate JSON file content into the compose file Using openRawResource you can instantiate your JSON file which is residing in the raw folder Linking MotionScene objects with appropriate composable can be done this way val context LocalContext currentval motionScene remember context resources openRawResource R raw motion scene readBytes decodeToString MotionLayout motionScene MotionScene content motionScene Time to comprehend MotionSceneMotionScene file consists of the following components ConstraintSets ConstraintSets are the building blocks of a MotionScene They define the layout and styling properties of the UI elements A ConstraintSet contains a set of constraints which specify the position size margin padding and other layout properties of each UI element Transitions Transitions define the animation or transition between two ConstraintSets They specify the duration easing and other animation properties A Transition can contain multiple KeyFrame which defines the intermediate states of the animation or transition We ll talk in depth about attributes that are used inside Transitions in the forthcoming section KeyFrames KeyFrames define the intermediate states of a Transition They specify the properties of the UI elements at specific points in the animation or transition A KeyFrame can contain a set of PropertySets which specify the properties of the UI elements PropertySets PropertySets specify the properties of the UI elements in a KeyFrame They can contain properties such as position size margin padding background color text color and so on Let s have a look at TransitionsThink of Transitions as a container containing an arbitrary amount of transitions as per necessity Each Transition is given a name The name “default is special and defines the initial transition An illustration of a transition is given below Take a look at how and what attributes are being used within the Transitions block Transitions default from start to end pathMotionArc startHorizontal duration staggered onSwipe anchor box maxVelocity maxAccel direction end side start mode velocity KeyFrames KeyPositions target a frames percentX percentY KeyCycles target a frames period rotationX rotationY The above is the transition from ConstraintSet “start to “end paths Time for the investigation of Transitions terms from ーid of the ConstraintSet indicating the starting point to ーid of the ConstraintSet to end at duration ーtime taken by the transition to happen pathMotionArc ーmove in quarter ellipse arcs staggered ーobjects move in a staggered fashion Either based on start position or stagger value onSwipe ーenable drag gestures to control the transition KeyFrames ーmodify points between the transitions Some commonly used Transition key attributesAlpha You can apply alpha property frame wise within “KeyAttributes inside the JSON script alpha Visibility You can apply this property to the children views which we define as an object within the start and end ConstraintSets Scale To change the scale of the image as it moves That s where scaleX and scaleY properties come into the picture ScaleX ーTo scale an object like an image per se horizontally ScaleY ーTo scale an object vertically You can apply scaling properties in the following manner as shown below inside KeyAttributes scaleX scaleY ElevationIt provides elevation which is self explanatory right Rotation rotationX ーTo rotate flip twirl an object on X axis rotationY ーTo rotate flip twirl an object on Y axis Translation It enables you to control the positioning of the View on a different axis translationX ーFor horizontal positioning translationY ーFor vertical positioning translationZ ーTransition value is added to its elevation Custom propertiesCompose offers a range of custom properties that can be used to achieve additional customization in your UI However it s important to note that these properties need to be extracted and set manually Typical custom property set custom background FF textColor FFFFFF textSize In brief let s understand the usage of custom properties with one example using text color We use the textColor property to apply desired color properties You can apply this property directly to the respective children view where you want to make desired changes Simply apply hex color following the hashtag e g DFFDmotion text end motion divider end top motion divider bottom custom textColor B You can set the custom properties in a below mentioned way var myCustomProperties motionProperties id motion text Text text Hello Mind Dots modifier Modifier layoutId myCustomProperties value id background myCustomProperties value color background color myCustomProperties value color textColor fontSize myCustomProperties value fontSize textSize Debug animation pathsTo ensure precise animation MotionLayout provides a debugging facility that would exhibit the animation paths of all the components involved To enable debugging we simply can do that with the “debug parameter Note that by default the debug value is set to EnumSet of MotionLayoutDebugFlags NONE Here you can see that the paths are denoted by a dotted line These dotted lines would come to the rescue especially when you are dealing with complex animation while seeking precision and consistency across devices with different sizes and resolutions Now it s the time to dive in into the code partLet s start with defining the MotionScene file ConstraintSets Two constraint sets Start and End Collapsed start collapsing box width parent height start parent start end parent end bottom parent top translationZ alpha data content top collapsing box bottom bottom parent bottom start parent start end parent end content img Assigned ID for profile pic which we ll use in the code for the reference width height top parent top top Constraint gt Constraining to what where to Margin value start parent start start Constraint motion text top parent top start parent start translationZ piranha flower width height top collapsing box bottom end parent end translationZ piranha tunnel width height top collapsing box bottom end parent end translationZ Expanded end collapsing box Background width parent height start parent start end parent end top parent top translationZ alpha content img width height top data content top start parent start data content top collapsing box bottom start collapsing box start end collapsing box end motion text bottom collapsing box bottom start content img end piranha flower width height top collapsing box bottom end parent end translationZ piranha tunnel width height top collapsing box bottom end parent end translationZ Transitions to set transition properties between Start and End point default from start to end pathMotionArc startHorizontal Text will move down with slight circular arc KeyFrames KeyAttributes We define different Attr and how we want this to Animate during transition for a specific composable target content img collapsed gt expanded frames For frames we pass a List containing number between rotationZ For dangling effect translationX translationY translationZ target data content frames For frames we pass a List containing number between translationY Now we have used a scaffold to achieve collapsing feature For this we d require one file to represent the Top bar and another for the rest of the contents Composable fun MainScreenContent val marioToolbarHeightRange with LocalDensity current MinToolbarHeight roundToPx MaxToolbarHeight roundToPx val toolbarState rememberSaveable saver MiExitUntilCollapsedState Saver MiExitUntilCollapsedState marioToolbarHeightRange val scrollState rememberScrollState toolbarState scrollValue scrollState value Scaffold modifier Modifier fillMaxSize content MarioMotionHandler list populateList columns modifier Modifier fillMaxSize scrollState scrollState progress toolbarState progress Finally add list item content along with the collapsing animation components Here we ll be making use of the MotionScene file Composable fun MarioMotionHandler list List lt MiItem gt columns Int modifier Modifier Modifier scrollState ScrollState rememberScrollState contentPadding PaddingValues PaddingValues dp progress Float val context LocalContext current val chunkedList remember list columns list chunked columns To include raw file the JSON script file val motionScene remember context resources openRawResource R raw motion scene mario readBytes decodeToString readBytes gt cuz we want motionScene in a String format MotionLayout motionScene MotionScene content motionScene progress progress modifier Modifier fillMaxSize background MarioRedLight bg image Image painter painterResource id R drawable ic mario level contentDescription Toolbar Image contentScale ContentScale FillBounds modifier Modifier layoutId collapsing box fillMaxWidth drawWithCache val gradient Brush verticalGradient colors listOf Color Transparent Color Black startY size height endY size height onDrawWithContent drawContent drawRect gradient blendMode BlendMode Multiply alignment BiasAlignment f f f progress f Text Collapsing Text text stringResource id R string collapsing text minion color MarioRedDark modifier Modifier layoutId motion text zIndex f fontFamily FontFamily Font R font super mario bros FontWeight Light fontSize sp Main image Image painter painterResource id R drawable ic mario reversed contentScale ContentScale Fit modifier Modifier layoutId content img clip RoundedCornerShape dp contentDescription Animating Mario Image Grid Column modifier modifier verticalScroll scrollState layoutId data content background MarioRedLight Spacer modifier Modifier fillMaxWidth height contentPadding calculateTopPadding chunkedList forEach chunk gt Row modifier Modifier fillMaxWidth wrapContentHeight Spacer modifier Modifier fillMaxHeight width contentPadding calculateStartPadding LocalLayoutDirection current chunk forEach listItem gt GridCharacterCard miItem listItem modifier Modifier padding dp weight f val emptyCells columns chunk size if emptyCells gt Spacer modifier Modifier weight emptyCells toFloat Spacer modifier Modifier fillMaxHeight width contentPadding calculateEndPadding LocalLayoutDirection current Spacer modifier Modifier fillMaxWidth height dp piranha flower Image painter painterResource id R drawable ic piranha flower contentScale ContentScale Fit modifier Modifier layoutId piranha flower contentDescription Piranha Flower piranha tunnel Image painter painterResource id R drawable ic piranha tunnel contentScale ContentScale Fit modifier Modifier layoutId piranha tunnel contentDescription Piranha Tunnel Files for character cards of the grid list Composable fun GridCharacterCard miItem MiItem modifier Modifier Modifier Card modifier modifier aspectRatio f shape RoundedCornerShape dp Box modifier Modifier fillMaxSize background Gray miItem itemImage let painterResource it let Image painter it contentDescription miItem itemDescription contentScale ContentScale FillWidth modifier Modifier padding dp fillMaxWidth TopBar miItem itemName let BottomBar it Composable private fun BoxScope TopBar Box modifier Modifier fillMaxWidth fillMaxHeight f background MarioRedDark padding horizontal dp vertical dp align Alignment TopCenter Row modifier Modifier fillMaxHeight f wrapContentWidth align Alignment CenterStart horizontalArrangement Arrangement spacedBy dp verticalAlignment Alignment CenterVertically Icon imageVector Icons Rounded Star contentDescription Golden star tint GoldYellow Icon imageVector Icons Rounded Star contentDescription Golden star tint GoldYellow Icon imageVector Icons Rounded Star contentDescription Golden star tint GoldYellow Row modifier Modifier fillMaxHeight f wrapContentWidth align Alignment CenterEnd horizontalArrangement Arrangement spacedBy dp verticalAlignment Alignment CenterVertically Image painter painterResource id R drawable ic coin contentScale ContentScale Fit modifier Modifier clip RoundedCornerShape dp contentDescription Coin Text text color Color Black modifier Modifier fontFamily FontFamily Font R font super mario bros FontWeight Normal Composable private fun BoxScope BottomBar text String Box modifier Modifier fillMaxWidth fillMaxHeight f background MarioRedDark align Alignment BottomCenter Text text text textAlign TextAlign Center maxLines overflow TextOverflow Ellipsis modifier Modifier fillMaxWidth align Alignment Center fontFamily FontFamily Font R font super mario bros FontWeight Normal To fully grasp the impact of the code snippets I suggest you take a closer look like Neo did in The Matrix ClosureThat s a wrap for now I hope this blog has inspired you to explore the endless possibilities of MotionLayout with Jetpack Compose Keep experimenting and pushing the boundaries of what is possible with this powerful framework You can access the source code from Github GitHub Mindinventory MarioInMotion Creating a collapsing toolbar with delightful animation in…Stay tuned for more Jetpack Compose tips and tricks |
2023-07-24 12:39:45 |
海外TECH |
DEV Community |
🚀 Building a contacts management system with NextJS, Supabase, and Flatfile 🥂 |
https://dev.to/github20k/building-a-contacts-management-system-with-nextjs-supabase-and-flatfile-5dk6
|
Building a contacts management system with NextJS Supabase and Flatfile TL DRToday I am going to build a contacts management system You can add all your contacts from different resources from any type size of file Edit them inline dynamically like an Excel sheet Get live updates when somebody else changes the worksheet ️Let s do it Manage your contacts live We will build a cool Excel spreadsheet that can be updated live For that we must use Websockets or Server Sent Events SSE To simplify the process we will use Supabase real time What is Supabase real time Supabase real time is pretty neat It s basically a Postgres database living up there in the cloud and when something changes there it sends an event through WebSockets about the new change You can learn more about WebSockets here Let s set it up Let s start by initiating a new NextJS project npx create next app latest contactsWe will not use the new app router for that project so please select that you don t want it To use Spreadsheets let s install react spreadsheet It s a young library but I have high hopes for it npm install react spreadsheet saveLet s open our index tsx inside of pages and add our data state and react spreadsheet import Spreadsheet from react spreadsheet export default function Home const data setData useState lt value string gt return lt div className flex justify center items stretch gt lt div className flex flex col gt lt Spreadsheet darkMode true data data gt lt div gt lt div gt Ok so not much to see be we will get there The react spreadsheet comes out of the box with the option to modify the column within But it s missing the option to Add new columnsAdd new rowsRemove columnsRemove rowsSo let s add those but before we do there is a small thing we have to take care of We don t want to spam Supabase with changes on every single word change The easiest way is to use a debouncer Debouncer who A debouncer is a way to tell our function activate me after X time has passed since I was triggered So if the users try to change the text it will only trigger the function second after they finish Let s install the debouncer npm install use debounce saveAnd import it to our project import useDebouncedCallback from use debounce Not we can create our update functionconst debouncer useDebouncedCallback newData any diff gt setData oldData gt update the server with our new data updateServer diff return newData As you can see the debouncer updates our data from the state but the function will only activate ms after the user triggers the function The main problem is that the debouncer is unaware of the data mutation data by reference And because it doesn t know it s better to check it before So here is the function that gets the new data from the lt Spreadsheet gt and if something really changes it will trigger our debouncer const setNewData newData value string ignoreDiff boolean gt This function will tell us what actually changed in the data the column row const diff findDiff data newData Only if there was not real change or we didn t ask to ignore changes trigger the debouncer if diff ignoreDiff return debouncer newData diff Now let s write the findDiff function It s a simple comparison between two dimensional arrays const findDiff useCallback oldData value string newData value string gt for let i i lt oldData length i for let y y lt oldData i length y if oldData i y newData i y return oldValue oldData i y value value newData i y value row i col y And now we can let our Spreadsheet update our data lt Spreadsheet darkMode true data data className w full onChange setNewData gt As I said before react spreadsheet is not mature enough yet so let s build our missing functions Add a new columnconst addCol useCallback gt setNewData data length value data map p any gt p value true data Add a new rowconst addRow useCallback gt setNewData data data map gt value value true data Remove a column by indexconst removeCol useCallback index number gt event any gt setNewData data map current gt return current slice index current slice index true event stopPropagation data Remove a row by indexconst removeRow useCallback index number gt event any gt setNewData data slice index data slice index true event stopPropagation data Now let s add the buttons to add a new row and column lt div className flex justify center items stretch gt lt div className flex flex col gt lt Spreadsheet darkMode true data data className w full onChange setNewData gt lt div onClick addRow className bg border border border t mb px flex justify center py cursor pointer gt lt div gt lt div gt lt div onClick addCol className bg border border border l mb px flex items center px cursor pointer gt lt div gt lt div gt The next part is tricky As I said before the library is a little immature lt div className flex justify center items stretch gt lt div className flex flex col gt lt Spreadsheet columnLabels data map d index gt lt div key index className flex justify center items center space x gt lt div gt String fromCharCode index lt div gt lt div className text xs text red onClick removeCol index gt X lt div gt lt div gt rowLabels data map d index gt lt div key index className flex justify center items center space x gt lt div gt index lt div gt lt div className text xs text red onClick removeRow index gt X lt div gt lt div gt darkMode true data data className w full onChange setNewData gt lt div onClick addRow className bg border border border t mb px flex justify center py cursor pointer gt lt div gt lt div gt lt div onClick addCol className bg border border border l mb px flex items center px cursor pointer gt lt div gt lt div gt The columnLabels and rowLabels expect to get back an array of strings but we give it an array of components You might need to use it with ts ignore so this is how it should look now Everything runs locally ATM let s send a request to the server with our update First let s install axiosnpm install axios saveimport it import axios from axios And write our updateServer function const updateServer useCallback serverData value string col number row number gt if serverData return console log serverData return axios post api update record serverData Supabase time Head to Supabase and register Go to projects and add a new Project Now go to the SQL editor and run the following query CREATE TABLE public values id INT GENERATED ALWAYS AS IDENTITY PRIMARY KEY row smallint DEFAULT smallint column smallint DEFAULT smallint value text UNIQUE row column This query creates the table values that contain the row and column numbers in our Spreadsheet We also added a UNIQUE key on both together rows and columns because we can only have one match in our DB We can upsert to the table since we mark them both in UNIQUE So if the value exists we just update it Since we will do SELECT queries from the client let s give the SELECT permission to everybody and then enable RLS Now let s review our settings and copy our anon public and service role secret keys Create a new file inside of your project called envtouch envAnd add the keys insideSECRET KEY service role keyNEXT PUBLIC ANON KEY anon keyNow let s install supabase jsnpm install supabase supabase jsCreate a new folder called helpers add a new file called supabase ts and add the following code import createClient from supabase supabase js You can take the URL from the project settingsexport const createSupabase key string gt createClient key Now create a new folder inside of pages called api most likely the folder exists already Create a new file called update record ts and add the following code import type NextApiRequest NextApiResponse from next import createSupabase from contacts helpers supabase const supabase createSupabase process env SECRET KEY export default async function handler req NextApiRequest res NextApiResponse if req method POST typeof req body col undefined typeof req body row undefined typeof req body value undefined res status json valid false return const data error await supabase from values upsert column req body col row req body row value req body value onConflict row column select res status json valid true Let s see what s going on here We import the previously created supabase ts file and initiate a new instance with our SECRET KEY this is important because only with our SECRET KEY can we mutate the database In the route we check that the method is POST and that we have values in col row and value It s important to check for undefined because we might get or empty values Then we do an upsert query that basically adds the row column and value but if it exists it just updates it Now let s listen to changes on the client side and update our spreadsheet Import superbase again but this time we will use the ANON keyimport createSupabase from contacts helpers supabase const supabase createSupabase process env NEXT PUBLIC ANON KEY And now let s add a useEffect to our component useEffect gt supabase channel any on lt any gt postgres changes event schema public table values payload gt console log payload new setData odata gt const totalRows payload new row gt odata length payload new row odata length const totalCols payload new column gt odata length payload new column odata length return new Array totalRows map row gt return new Array totalCols map col gt if payload new row row amp amp payload new column col return value payload new value return value odata row col value subscribe We subscribe to the values table and update our data anytime we get changes Let s look at a few highlights here data format usually looks something like this row col row col row col row col row col row col row col row col But what happens if we get row col but we don t have row col row col row col So to solve that we just need to check for the highest row and the highest col and create a dimensional array with the values The …new Array value is a cool trick to create an array with empty values in your desired size Awesome we have built the entire contacts system but that s not the end Let s import all your contacts from other resources Even if you have thousands of contacts we can easily add them using FlatFile FlatFile is the easiest fastest and safest way for developers to build the ideal data file import experience Those are the steps we are going to take We add the FlatFile React Component to load any file type CSV XSLX XML etc We create a function that processes this file and insert the contacts into our database We deploy the function to the cloud and FlatFile will take care of everything without our need to maintain it anymore So go ahead and register to Flatfile head to settings and copy the Environment ID Publishable Key and Secret KeyAnd paste them into our env file NEXT PUBLIC FLAT ENVIRONMENT ID us env NEXT PUBLIC FLAT PUBLISHABLE KEY pk FLATFILE API KEY sk The Space FlatFile has a concept called Spaces which are micro applications each with its own database filestore and auth Inside each space are different WorkBooks which are basically a group for different spreadsheets Each time we want to load contacts we will create a new space with one workbook and one sheet Now let s install the FlatFile React component npm install flatfile react saveLet s create a new folder called components and create our file importer mkdir componentscd componentstouch file importer tsxAnd then create a button to import our contactsconst FileImporterComponent FC lt data string gt props gt const data props const showSpace setShowSpace useState false return lt div className flex justify center py gt lt button className bg violet p rounded xl onClick gt setShowSpace showSpace gt Import Contacts lt button gt showSpace amp amp lt div className fixed w full h full left top z text black gt lt div className w m auto top absolute left translate x translate y text black space modal gt lt FlatFileComponent data data closeSpace gt setShowSpace false gt lt div gt lt div gt lt div gt export default FileImporterComponent As you can see we are passing a parameter called data that s basically the name of all our headers the first row in our spreadsheet from the previous step We will send them to FlatFile and FlatFile will try to guess which field belongs to which field Once we click on the Import Contacts button it will open the FlatFile components Now let s create our FlatFile component const FlatFileComponent FC lt data string closeSpace gt void gt props gt const data closeSpace props const theme useMemo gt name Dynamic Space environmentId us env nSuIcnJx publishableKey process env NEXT PUBLIC FLAT PUBLISHABLE KEY themeConfig makeTheme primaryColor a textColor fff workbook name Contacts Workbook sheets name ContactSheet slug ContactSheet fields data map p index gt key String index type string label p actions label Submit operation contacts submit description Would you like to submit your workbook mode background primary true confirm true as ISpace data const space useSpace theme closeSpace operation contacts close onClose gt closeSpace return lt gt space lt gt Let s see what s going on here We use the React hook of useSpace to initiate a new FlatFile wizard We pass the environmentId and publishableKey that we got from the settings We map the fields from the name of our headers In the key I pass the header index so when I insert it later to Supabase I know the column number We set an action of submit and we set the mode to be background because we don t want to process the data over the front we basically can t because our Anon user doesn t have access to INSERT into our database Let s add our component to our main page FlatFile uses the window object Since we are using NextJS we cannot access the window object during server rendering We have to use a dynamic import to add it import dynamic from next dynamic const FileImporterComponent dynamic gt import components file importer ssr false return lt gt data length amp amp lt SpaceComponent data data map p gt p value gt lt div className flex justify center items stretch gt lt div className flex flex col gt lt Spreadsheet columnLabels data map d index gt lt div key index className flex justify center items center space x gt lt div gt String fromCharCode index lt div gt lt div className text xs text red onClick removeCol index gt X lt div gt lt div gt rowLabels data map d index gt lt div key index className flex justify center items center space x gt lt div gt index lt div gt lt div className text xs text red onClick removeRow index gt X lt div gt lt div gt darkMode true data data className w full ts ignore onChange setNewData gt lt div onClick addRow className bg border border border t mb px flex justify center py cursor pointer gt lt div gt lt div gt lt div onClick addCol className bg border border border l mb px flex items center px cursor pointer gt lt div gt lt div gt lt gt Once you save everything you should see something like this Awesome The only thing left is to load everything into our database Let s install some FlatFile dependenciesnpm install flatfile listener flatfile api saveCreate a new file called listener tsThis is a special file that listens to file imports Let s import FlatFile and Supabase import FlatfileEvent Client from flatfile listener import api from flatfile api import createSupabase from src database supabase const supabase createSupabase process env SECRET KEY We can add our listener of contacts submit that we have coded in the previous steps export default function flatfileEventListener listener Client listener filter job workbook contacts submit configure gt configure on job ready async context jobId workbookId payload FlatfileEvent gt add to supabase To insert the new values we need to take the highest row currently in the DB and increment it const row await supabase from values select row order row ascending false limit let startRow row data length row data row Then we take all the records in the imported fileconst data sheets await api sheets list workbookId const records await api records get sheets id data records We fetch and add them to our database We also use the api jobs ack call to inform the user of the front about the progress of the import for const record of records await api jobs ack jobId info Loading contacts progress Math ceil index records length await Promise all Object keys record values map key gt console log row startRow column key value record values key value return supabase from values upsert row startRow column key value record values key value onConflict row column select startRow index Once the import is completed we can finish the job on the client side await api jobs complete jobId outcome message Loaded all contacts The full listener ts file should look like this import FlatfileEvent Client from flatfile listener import api from flatfile api import createSupabase from src database supabase const supabase createSupabase process env SECRET KEY export default function flatfileEventListener listener Client listener filter job workbook contacts submit configure gt configure on job ready async context jobId workbookId payload FlatfileEvent gt const row await supabase from values select row order row ascending false limit let startRow row data length row data row const data sheets await api sheets list workbookId loading all the records from the client const records await api records get sheets id data records let index try for const record of records information the client about the amount of contacts loaded await api jobs ack jobId info Loading contacts progress Math ceil index records length inserting the row to the table each cell has a separate insert await Promise all Object keys record values map key gt console log row startRow column key value record values key value return supabase from values upsert row startRow column key value record values key value onConflict row column select startRow index catch err failing the job in case we get an error await api jobs fail jobId info Could not load contacts return Finishing the job await api jobs complete jobId outcome message Loaded all contacts To recap everything We created a new file called listener ts that listens to new imports We added a filter called workbook contacts submit to catch all the contacts imports you can have multiple filters in case you have files import in different places We iterate over the contacts and add them to our DB We inform the client about the percentage of our progress with api jobs ackIf there is a failure we will inform the client with api jobs fail If everything is okay we will inform the client with api jobs completeYou can learn more about how to use the events here Save the file and run it withnpx flatfile develop listener tsAnd when you are ready to deploy it just usenpx flatfile deploy listener tsThis is pretty amazing because if you deploy it you don t need to run this command again You will also see the logs inside the Flatflie dashboard Let s run the develop command import our CSV file and see what happens I hope you enjoyed this one I certainly did For the full source code please visit Worth checking them outif you plan on implementing any kind of feature that involves importing or exchanging data files Go ahead and check FlatFile I had tons of fun playing with them You can get started here for free |
2023-07-24 12:30:23 |
海外TECH |
DEV Community |
Background Tasks and Scheduled Jobs in .NET? Meet Hangfire🔥 |
https://dev.to/bytehide/background-tasks-and-scheduled-jobs-in-net-meet-hangfire-30pd
|
Background Tasks and Scheduled Jobs in NET Meet HangfireDo you often find yourself grappling with managing background tasks and scheduled jobs in your NET or C applications Thankfully there s Hangfire to simplify this convoluted process and make our lives a whole lot easier In the forthcoming sections we will deep dive into the workings of Hangfire its implementation in NET and C and the future it holds Understanding Hangfire An OverviewThe digital sphere is surging towards asynchronous computing demanding reliable tools to manage background tasks Hangfire plays hero in charting these unexplored terrains In the sections that follow we will unfold what Hangfire truly is get our hands code dirty and see its impact on Background tasks and scheduled jobs What is Hangfire Simplicity is the ultimate sophistication Hangfire personifies this adage by streamlining the management of background tasks in NET and C Hangfire is an open source framework that aids developers in executing arranging and managing background tasks within any NET application It supports both NET Framework and NET Core Scheduling a background job using Hangfire BackgroundJob Enqueue gt Console WriteLine Welcome to the Hangfire World In this simplified example we use Enqueue method to execute a method asynchronously in the background When this line of code is hit during program execution Hangfire will ensure Console WriteLine Welcome to the Hangfire World is run no matter how long the application is alive But hang on it s not just simplicity that Hangfire brings to the table It boasts some remarkable features like Task Persistence Hangfire uses persistent storage saving tasks to be processed It keeps your tasks safe and not prone to process recycles machine restarts or any unexpected failures Automatic Retries Hangfire automatically retries failed tasks so you don t have to manually handle exceptions Dashboard UI Its intuitive dashboard provides a visual runtime representation of scheduled processing succeeded and failed jobs Support for CRON expressions For complex scheduling it even supports CRON expressions Now you might be thinking “That s great but how could year olds make of this Think about Hangfire as a trustworthy chef cooking up all your favorite dishes background tasks following your instructions job scheduling and serving them right on time every time regardless of problems in the kitchen crashes errors shutdowns The Role of Hangfire in Background Tasks and Scheduled JobsWhen it comes to managing background jobs in NET and C you might think of using chron jobs or intricate threading logic But here s where Hangfire recalibrates the paradigm and allows you to wave goodbye to those complicated alternatives Hangfire enables smoothening of operations that require substantial processing time such as data exports email notifications backups by executing these tasks asynchronously in the background This in turn significantly improves application responsiveness An example of scheduling recurring email notifications job using HangfireRecurringJob AddOrUpdate gt EmailService SendNotifications Cron Daily In this snippet AddOrUpdate schedules EmailService SendNotifications to run as a daily recurring job Hangfire uses the Cron class to express complex schedules as simple Cron expressions For another real life example imagine a news agency system Every night they want to automatically send a summary of the day s important news to their subscribers Instead of employing someone to do this manually every night they could use Hangfire to schedule this operation An example of scheduling a daily news summary email using HangfireRecurringJob AddOrUpdate gt NewsService SendDailyNewsSummary Cron Daily In this code RecurringJob AddOrUpdate is used to run NewsService SendDailyNewsSummary as a daily recurring job at midnight Hangfire will ensure the subscribers receive their news summary email every day like clockwork regardless of any issues Indeed the revolution of background tasks and scheduled jobs has a new battlefield Hangfire Ready to go deeper Let s dive in Delving Deeper into Hangfire NETWith the stage set let s take a deep dive into the operational waters of Hangfire with NET We will unfold how Hangfire breathes life into the architecture simplifies installs boasts enthralling features and offers real world applications Buckle up and enjoy the ride The Architecture of Hangfire NETIn the realm of Hangfire everything revolves around jobs Jobs in Hangfire are versioned retried queued and distributed across available workers Let s break down Hangfire s architectural components Enqueuing When a job is created it s dispatched to queues Execution Workers continuously poll for jobs on these queues Retry If a job fails it s moved to a retries queue and attempted later Versioning Older versions of jobs are preserved for a smooth scaling process Ever wondered how to create a job that runs every minute Even year olds can do this Here s a catchy rhyme to remember Schedule a job to print Hi every minuteRecurringJob AddOrUpdate gt Console WriteLine Hi Cron Minutely Isn t it as easy as ABC Installing and Configuring Hangfire in NETImplementing Hangfire in your NET application is as simple as setting up a new video game albeit a little different After installing the Hangfire NuGet package add the following code to Startup cs public void Configuration IAppBuilder app Configuring Hangfire job storage Let s use SQL Server GlobalConfiguration Configuration UseSqlServerStorage lt connection string gt Setting up Hangfire Dashboard and Server in a NET application app UseHangfireDashboard app UseHangfireServer Voila You ve set up Hangfire successfully Head to lt your app url gt hangfire to view the rich inbuilt dashboard where all your jobs live Understanding Hangfire NET FeaturesHangfire NET encapsulates a slew of features that can knock your socks off From managing job lifecycles to supporting complex task structures Hangfire has a lot in store Notable features include Automatic Retry Hangfire automatically retries failed jobs based on an exponential back off algorithm Server Lists Hangfire servers automatically join or leave the cluster dynamically to maintain high availability Job Continuations You can ensure Job B runs after Job A by utilizing the ContinueWith statement Advanced Job Filters Custom job filters allow you to add event hooks for success and failure cases Check out how to queue a background job followed by a continuation job Let s queue a background job and a continuation jobvar jobId BackgroundJob Enqueue gt Console WriteLine Background job BackgroundJob ContinueWith jobId gt Console WriteLine Continuation job You see Hangfire is your consideration when one job swings into action after another Hangfire NET in Action Practical ExamplesNow let s move Hangfire from theoretical discussion to practical action Ever wanted to send users a welcome email an hour after registration Or delete inactive users after a month Hangfire pitchforks asynchronous coding into child s play Send a welcome email hour after user registrationvar userId BackgroundJob Schedule gt SendWelcomeEmail userId TimeSpan FromHours With this an email will be sent to the user one hour after running the background jobーtruly asynchronous For a more real life application consider a system that deletes inactive users after a month In Hangfire it s a cakewalk Delete inactive users after a monthRecurringJob AddOrUpdate gt DeleteInactiveUsers Cron Monthly With Hangfire NET you can brew many such recipes automating tasks and giving your applications a sharp edge Hangfire C and its significanceWho said a simple programming language and a robust task scheduling framework can t craft magic together Let s dive into this enticing fusion of C and Hangfire and discover how it simplifies our complex coding lives one task at a time How Hangfire Complements CWhile C is an object oriented language cherished for its simplicity and power Hangfire slides into this scenario adding the cherry of scheduling and managing background tasks efficiently to the C cake No more wrestling with threads and timers Let s schedule a task that will run after exactly five minutes Scheduling a background job to run after minutesBackgroundJob Schedule gt Console WriteLine Just Hangfiring TimeSpan FromMinutes Here we use Hangfire s Schedule method passing our task printing “Just Hangfiring and the delay time as parameters Configuring Hangfire in a C projectSetting up Hangfire in a C project is so easy even a kid could do it Setting up Hangfire in Startup cs public void Configuration IAppBuilder app app UseHangfire config gt config UseSqlServerStorage lt your connection string gt app UseHangfireDashboard app UseHangfireServer In the given code snippet we configure Hangfire with our SQL Server instance set up the Hangfire Dashboard for monitoring and start the Hangfire server Simple isn t it Key Features of Hangfire CHangfire shines with its features that empower C in unique ways Automatic retries Tasks fail sometimes but Hangfire ensures they get another shot at success Exception handling Hangfire can gracefully catch and manage exceptions saving your application from potential downtime Task prioritization Because not all tasks are equal some deserve higher priority Custom failure strategies If a task fails you decide what happens next Scheduled tasks Be it daily weekly or once in a blue moon schedule your tasks with great ease Real time Applications of Hangfire in CThe real magic of Hangfire is observed in real world applications For a blogging website scheduling routine tasks such as sending newsletters cleaning up old articles or auto publishing scheduled blog posts can all be smoothly handled with Hangfire Scheduling a recurring job for clearing old articles RecurringJob AddOrUpdate gt new ArticleService ClearOldArticles Cron Monthly In this example we schedule a recurring job using RecurringJob AddOrUpdate which calls the ClearOldArticles method of ArticleService every month Bringing this down to a more relatable level think of Hangfire as your personal assistant You want to bake cookies but you need to keep stirring the mixture for minutes well you just delegate this to Hangfire and voila you can enjoy your favorite TV show while Hangfire stirs the mixture for you Now isn t that your favorite part of the cookie baking process made simpler Debugging and Troubleshooting with HangfireEven roses have thorns and so does coding Despite the sweetness Hangfire provides there exist challenges But no worries sailing through the storm is easier with the right knowledge We ll explore some common issues debugging tips and learn how to efficiently monitor jobs Common Issues in Hangfire and their SolutionsLet s not sugarcoat it you might encounter issues while using Hangfire Don t let these derail your progress though Here are common ones and their simple solutions Stalled Recurring Job Common yet puzzling recurring jobs might halt unexpectedly Typically caused by an error within the job itself Investigating the exception log in the Hangfire dashboard usually points to the problem Recurring Job SetupRecurringJob AddOrUpdate gt Console Write Daily Cron Daily Let s assume an exception occursRecurringJob AddOrUpdate gt throw new Exception Oops Cron Daily In this example the job fails due to an exception and Hangfire suspends its execution until the problem is addressed Unprocessed Queue Hangfire custom queues can remain unprocessed if there s a misconfiguration in the Hangfire server A classic pitfall that s easily avoidable through a correct setup Incorrect Server Setupvar options new BackgroundJobServerOptions Queues new critical default app UseHangfireServer options This server will not process jobs in a custom queue named “emailSend To fix it include “emailSend in the queue list Failed Jobs Stuck in Retry State Hangfire retries failed jobs automatically However there can be cases where jobs remain stuck in the retry state The reason could be an unhandled exception within your job code Looking into the exception log should provide information on handling the error and getting your jobs back on track Tips for Efficient Debugging in Hangfire“Just because debugging is twice as hard as writing a program does that mean if you write a program ineffably well you won t have to debug it Good question let s find out Logging Hangfire supports built in logging mechanisms such as lognet NLog and Serilog Use these to your advantage for comprehensive monitoring Exception handling Unhandled exceptions will disrupt your job processing Consider wrapping your job execution codes within try catch blocks to ensure smooth job processing try BackgroundJob Enqueue gt Console Write No Errors Here catch Exception ex Console WriteLine Oops something went wrong ex Message This simple safeguard can save you hours of debugging trust me Use Dashboard The Hangfire Dashboard isn t just pretty it s a powerhouse of tools and utilities for debugging and tracking job progress failed jobs and retry attempts Employ Good Coding Practices As always following good coding practices will help prevent bugs from creeping into your jobs Stringently validate your input data and anticipate error occurrences Maintaining and Monitoring Jobs in HangfireHangfire Dashboard is like a control room equipped with all you need to monitor and wield power over your jobs Here are a few pointers to effectively use it Have a hawk eye on the Job graph It provides a bird s eye view of your jobs their states success rates and failures if any Check queues If jobs seem to be stuck the queue status might have a hint for you Failed jobs Hangfire classifies failed jobs differently Examine the exceptions encountered by the “Failed jobs to fix and resume them Advanced Concepts in Hangfire“But wait there s more Let s lift the hood and delve into the advanced mechanics of Hangfire In this section we will walk you through scaling with distributed processing getting insights into security considerations and enhancing Hangfire with extensions and improvements So buckle up and brace for a deep dive Scaling with Hangfire Distributed Background Job ProcessingUnleash the power of distributed processing with Hangfire This concept hugely benefits large scale applications with a massive job load But how does it work exactly Setting up distributed Hangfire servers across different machinesservices AddHangfire configuration gt configuration SetDataCompatibilityLevel CompatibilityLevel Version UseSimpleAssemblyNameTypeSerializer UseRecommendedSerializerSettings UseSqlServerStorage Configuration GetConnectionString HangfireConnection new SqlServerStorageOptions CommandBatchMaxTimeout TimeSpan FromMinutes JobExpirationCheckInterval TimeSpan FromHours CountersAggregateInterval TimeSpan FromMinutes PrepareSchemaIfNecessary true QueuePollInterval TimeSpan Zero UseRecommendedIsolationLevel true UsePageLocksOnDequeue true DisableGlobalLocks true This is an instance of how to set up a distributed Hangfire server system The UseSqlServerStorage function is configuring the connection towards SQL Server and the DisableGlobalLocks facilitates distributed locks for the servers Now imagine slicing up a giant pizza the job among your friends the distributed servers More hands less time to devour the pizza same concept Security Aspects of Using HangfireSecurity and programming go hand in hand Hangfire isn t an exception it offers a secure dashboard that prevents unauthorized access But how secure is it you ask Set up strict Dashboard access authorization rulesapp UseHangfireDashboard hangfire new DashboardOptions DashboardTitle My Hangfire Dashboard Authorization new new HangfireCustomAuthorizeFilter public class HangfireCustomAuthorizeFilter IDashboardAuthorizationFilter public bool Authorize DashboardContext context Check user authorization here return true if authorized return HttpContext Current User IsInRole Admin This code snippet configures the Hangfire dashboard and includes an authorization filter It ensures that only users in the “Admin role can access the dashboard The consequences of an unauthorized user invading the dashboard Let s just say it s like a dog getting hold of your homework not pretty Enhancements and Extensions in HangfireHangfire is more than just a tool it s a playground for developers With numerous extensions at disposal you can tailor Hangfire to your specific needs Want to see how it s done Logging job events using Hangfire Console extensionBackgroundJob Enqueued sender args gt Log Information Job args JobId has been enqueued Sample job using Hangfire ConsoleBackgroundJob Enqueue gt ConsoleJob public void ConsoleJob PerformContext context context WriteLine Hello Hangfire Console In this example we used the Hangfire Console extension to log job events back to the console The ConsoleJob is logging a greeting message on execution Conclusion Summarizing the Power of Hangfire in NET and COur journey with Hangfire seems to be taking off just as we are wrapping up But fret not there s always more to explore and learn Hangfire surely seems like the afterburner we needed to take our NET and C projects to the skies doesn t it |
2023-07-24 12:26:55 |
海外TECH |
DEV Community |
PrimeFaces v13.0.0 Released |
https://dev.to/cagataycivici/primefaces-v1300-released-6io
|
PrimeFaces v ReleasedPrimeFaces UI component library is back with a new major release featuring over improvements JSF is alive Well yes PrimeFaces has been initiated back in late and after all these years thanks to the great community contributions it is still a healthy open source project with constant updates Considering the fast paced nature of Javascript ecosystem a year old UI library with million download per year is exceptional For form driven back office apps it is still a viable choice in a Jakarta EE environment Free Themingv is special because we re introducing some new changes and open sourcing some of the paid add ons like theming Theme Designer was a paid add on and with v it is not available as open source view the new theming documentation for details and tutorials We ll also come up with a new video tutorial The visual editor now permits downloading the created themes as well in case you don t want to go through the details of the theming API Material and Bootstrap themes are also open sourced and available at github Elite to LTSPrimeFaces Elite will be replaced with LTS like PrimeNG has this means maintenance versions of the last major version will now be open source starting with In the past was only available to paying users Special ThanksA big shout out the community leaders of PrimeFaces without their contributions it would be impossible to maintain the library PrimeFaces is a fantastic example of a community driven project tandraschkojepsarmellowareRapsterchristophs ChangelogVisit the changelog for the complete list of changes RoadmapCompared to other Prime UI libraries like PrimeNG PrimeReact and PrimeVue PrimeFaces still uses an older theming API with ui prefix We re planning to migrate to p prefix and move to CSS variables from SASS |
2023-07-24 12:23:06 |
Apple |
AppleInsider - Frontpage News |
New Apple Watch Ultra will be lighter, claims leaker |
https://appleinsider.com/articles/23/07/24/new-apple-watch-ultra-will-be-lighter-claims-leaker?utm_medium=rss
|
New Apple Watch Ultra will be lighter claims leakerA leaker with a short but good record for information on Apple releases claims that the expected second generation Apple Watch Ultra will be lighter than the first Apple Watch UltraThe first generation Apple Watch Ultra weighs g lbs but the leaker gives no indication of how much lighter the next model is supposed to be The new Apple Watch Ultra has reduced weight is the entirety of the leak in translation from its original posting on Chinese social media site Weibo Read more |
2023-07-24 12:06:51 |
医療系 |
医療介護 CBnews |
後発薬の業界再編へ厚労省が検討会-31日に初会合、安定供給の実現巡り |
https://www.cbnews.jp/news/entry/20230724212333
|
厚生労働省 |
2023-07-24 21:50:00 |
ニュース |
BBC News - Home |
George Alagiah: BBC journalist and newsreader dies aged 67 |
https://www.bbc.co.uk/news/entertainment-arts-65949435?at_medium=RSS&at_campaign=KARANGA
|
british |
2023-07-24 12:36:16 |
ニュース |
BBC News - Home |
Empathy was George’s great strength, he radiated it |
https://www.bbc.co.uk/news/entertainment-arts-66136159?at_medium=RSS&at_campaign=KARANGA
|
allan |
2023-07-24 12:05:52 |
ニュース |
BBC News - Home |
Elon Musk: Twitter rebranded as X as blue bird logo killed off |
https://www.bbc.co.uk/news/business-66284304?at_medium=RSS&at_campaign=KARANGA
|
billionaire |
2023-07-24 12:09:14 |
ニュース |
BBC News - Home |
Greta Thunberg fined over Swedish climate protest |
https://www.bbc.co.uk/news/world-europe-66287756?at_medium=RSS&at_campaign=KARANGA
|
malmo |
2023-07-24 12:11:25 |
ニュース |
BBC News - Home |
Kylian Mbappe: Al Hilal make £259m offer for PSG and France forward |
https://www.bbc.co.uk/sport/football/66291108?at_medium=RSS&at_campaign=KARANGA
|
kylian |
2023-07-24 12:47:32 |
ニュース |
BBC News - Home |
Russia accuses Ukraine of Moscow drone attack |
https://www.bbc.co.uk/news/world-europe-66286102?at_medium=RSS&at_campaign=KARANGA
|
buildings |
2023-07-24 12:06:17 |
ニュース |
BBC News - Home |
Women's World Cup 2023: Alexandra Popp and the ET goal celebration |
https://www.bbc.co.uk/sport/football/66290078?at_medium=RSS&at_campaign=KARANGA
|
Women x s World Cup Alexandra Popp and the ET goal celebrationAlexandra Popp scored twice in Germany s Women s World Cup win over Morocco but it was her goal celebration which caught the eye |
2023-07-24 12:42:46 |
ニュース |
Newsweek |
アディダスのシューズを買うなら今!半額以下のスニーカーも...注目商品を一挙紹介 |
https://www.newsweekjapan.jp/stories/lifestyle/2023/07/post-102255.php
|
アディダスのシューズを買うなら今半額以下のスニーカーも注目商品を一挙紹介人気商品が日替わりで登場するアマゾン「タイムセール」。 |
2023-07-24 21:30:00 |
コメント
コメントを投稿