I would personally go for using a class to apply colour rather than an inline stylesheet. This way if you need to change the colour being applied to the list element then you can just that once in the class and every list element will show the correct colour, otherwise you need to go through and change every inline style on the list elements.
I’m not sure how much difference between those two methods it would make from a performance / Google site speed score really, it depends on what level of detail you were examining performance. The class will certainly make it quicker to edit so that method would be the one I would go for.
Hope that helps!
Related Posts:
- ajaxurl not defined on front end
- Where to store PHP files created by plugin / themes
- How to post data to same page in wordpress
- Understanding WordPress functions’ naming conventions
- Is there widely accepted phpDoc syntax for documenting which hook calls a function?
- How do I Make a Theme “plugin-ready”?
- How to Add a .js file Only in one specific Page Dynamically to Head
- Show a user their recently viewed posts
- Escaping built-in WP function return strings
- How to use filter hook ‘post_updated_messages’ in coherence with action hook ‘save_post’
- Add new user and add meta at once
- Custom user profile, registration, login page with theme
- How to Display Custom Post Type’s Gallery (images ) in Through WP_Query
- What is better way to use Bootstrap inside admin panel?
- What’s the better way to add an inline script?
- Backslashes being stripped from CSS
- What for the tables ending with the meta used in database of wordpress?
- Filter, or any way to dynamically change theme screenshot image?
- Finding the paragraphs in content
- Is Dreamweaver CS5 a serious choice for theme/plugin development?
- What allows a template file from plugin to be copied in child theme and overridden?
- How to avoid loading same script twice?
- Can I individually style items in the backend widget list?
- WordPress security issue to output data from user input from theme option form
- Is using WP Transients to save external data for a plugin the best/right way?
- WP_Query returns no results
- Finding posts containing matching array elements in a meta field usign WP_Query
- Customizer: widget-synced triggers twice
- How to Create Custom HTML Tag on Editor in `Text(HTML)` mode
- Is It Always a Best Practice to Decouple the Frontend from the Admin Area When Developing a WordPress Application?
- Change the ‘published on’ text?
- How to render a time-of-day string like ’16:42′ with a site’s chosen time format?
- Are block templates incompatible with serialize_blocks?
- How to filter users list on user_status field with get_users()
- I’m designing a plugin to create database indexes. Suggestions?
- Can Page Templates be Applied to Archive and Post Templates?
- Is there some way to provide the user a list of existing content in a CPT
- Change the look and feel of admin pages
- How to access noticeOperations from withNotices
- How to get boolean value from register_meta properly?
- Form doesnt save to database
- Notice: Trying to get property ‘term_id’ of non-object
- What is the proper method of using global $post?
- How to export post meta with images in wordpress
- Password field is empty when using wp_signon();
- How to change title tag at page after loaded post?
- Strange Situation When Try To Retrieve Github Gist Using wp_remote_get
- WordPress custom taxonomy check box to dropdown
- Selectively update themes in WordPress multisite
- Widget HTML Display Problem
- How to create a backend for a custom theme?
- wp_nonce_field displaying twice
- WP Plugin Running before jQuery
- How to only load css for used blocks on frontend
- my own SVN for a plugin/theme
- Why enqueue styles on hook?
- Create Widget or Enable Shortcodes in Sidebar
- Getting a WordPress Debug Strategy
- PHP File_exist() not working – Checking if File Exist in WordPress Theme Directory
- Invalid hook call on save, not edit when using swiper slider
- Proper way to use useSelect
- Conditional Generation of Image Sizes using add_image_size
- modify show UI of a registered taxonomy
- Using function from enqueued .js file in theme in plugin?
- Using HTML links within translatable string
- How to get terms for taxonomy
- How to remove/replace current page template?
- WordPress Page Reload Takes forever during theme development
- Adjust query on single
- Using password protection to load different page elements?
- Anyone using unzip_file successfully? It uploads the zip but doesn’t extract it!
- Pass custom props to
- How do I add filter with woocommerce categories?
- Can’t upload image via submitting custom post from frontend
- Need Help to make a logic for editing posts in Frontend
- How can we stop showing short code in create or edit post section
- Error Connecting to Database WHEN Installing WordPress on XAMPP [Tried All the Usual Stuff] (Pics Included)
- How can I measure CPU and RAM used by my theme or plugin
- set a custom post type to a taxonomy term programmatically in metabox
- My enqueue admin style function doesn’t work because of ?=ver
- Can i prevent the effect of the_title filter on the dashboard’s posts/pages titles?
- How to embed or integrated a custom WordPress Widget into the theme?
- To remove rendering of menus and header, plugin or theme?
- Custom theme and plugin updating
- How can I add recent posts to menu like mashable
- Is there a general way to get a themes primary colour?
- problem with blank page
- How to Register/Link to .js Files in WordPress Dynamicaly in Header.php
- Best Way to Inventory the Media Library of a 200+ Multisite Installation?
- Loading jQuery library from WordPress admin
- how to insert content into wp_head after loop_end
- how many rupee or dollar charge to client to make theme [closed]
- how to catch a data from a array in WordPress
- How react js and other Javascript Technologies works on WordPress plugin?
- Is there any other ways to replicating changes on live from staging without pushing from git
- Hook a search form anywhere on the site, using a custom plugin
- Fetch Custom Woocomerce filed data and check the data avialble in Wp-user table as nicname or username using function.php
- How to boost WP custom post REST API GET queries by custom taxonomies
- Remove Gutenberg Buttons Block
- User set default settings for a Block in Site Editor