Production environment experiencing issues with CSS functionality. Combination of Vue.js, Tailwind, and Netlify not functioning as expected

I am completely baffled...this marks my second vue.js project. When I try to push the site live, it's causing me a lot of trouble.

The application functions perfectly locally, but after deploying to netlify and building it, the CSS seems to be malfunctioning. I have included purgecss in my postcss.config.js file:

const IN_PRODUCTION = process.env.NODE_ENV === 'production';

module.exports = {
    plugins: [
        require('tailwindcss')('tailwind.js'),
        require('autoprefixer')(),
        IN_PRODUCTION &&
            require('@fullhuman/postcss-purgecss')({
                content: ['./public/**/*.html', './src/**/*.vue'],
                defaultExtractor(content) {
                    const contentWithoutStyleBlocks = content.replace(
                        /<style[^]+?<\/style>/gi,
                        ''
                    );
                    return (
                        contentWithoutStyleBlocks.match(
                            /[A-Za-z0-9-_/:]*[A-Za-z0-9-_/]+/g
                        ) || []
                    );
                },
                whitelist: [],
                whitelistPatterns: [
                    /-(leave|enter|appear)(|-(to|from|active))$/,
                    /^(?!(|.*?:)cursor-move).+-move$/,
                    /^router-link(|-exact)-active$/,
                    /data-v-.*/,
                ],
            }),
    ],
};

Following the Tailwind CSS and PurgeCSS guidelines. It works fine locally, but not in production.

The Netlify build command is npm run build and it is served from the dist folder.

You can view the app here: And find the repository here: https://github.com/mrpbennett/beautify-url

I am not using scoped on my style tags

Any suggestions or ideas would be greatly appreciated.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Updating the content within a div using jQuery

I am facing an issue with refreshing 2 divs on my HTML page when an event is triggered. One of the divs has a style of display:none and is not updating with the new data. Is there a way to refresh divs that are set to display:none? Here is the JavaScript ...

In Next.js, fetch returns the data that is already present, not new data

Using fetch as an SSG method in Next.js has been a challenge for me. I have encountered a discrepancy between the 'content' value I registered in the mock server and the actual displayed value. Here is the code snippet: import Layout_Mobile fro ...

Updating and Preserving Content in Angular

I've encountered an issue while working on a code that allows users to edit and save a paragraph on the screen. Currently, the editing functionality is working fine and the save() operation is successful. However, after saving, the edited paragraph do ...

Tips for effectively showcasing the counter outcome amidst the increase and decrease buttons

Currently, I am in the process of learning Angular and have created a component called quantity-component. Within the quantity-component.component.html file, I have implemented 2 buttons for increment (denoted by +) and decrement (denoted by -). The decrem ...

What's the best way to display alert messages using the alert method in Node.js with Jade?

Is there a way to render a 'Jade view' with data? For example, in the following code: app.get('/', function(req, res){ res.render('alert', {msg: 'hi!'}); }); I attempted to write the Jade code below: (alert.ja ...

Guide to Including an Object in AngularJS Scope

I am completely new to Angular JS and mongod. My goal is to add a new ingredient field to this page for the specific drink that the + button is clicked on. Here is how my view looks like: UI Image This is what my .jade file contains: block content ...

Tips for handling the accent mark (diacritic mark)

My primary language is Spanish, which means I use accent marks quite frequently (á, é...). When I need to type them out, I resort to using &aacute;, &eacute;, and so on. However, I'm facing an issue when trying to compare two sentences in m ...

npm encountered an error due to an invalid query string passed to parseQuery. The proper format should include a question mark at the beginning

When I executed npm run build in my vue2 project, an error message appeared stating that loaderUtils.getOptions is not a function. After running cnpm install vue-loader vue-template-compiler loader-utils, I encountered the following error: ERROR in ...

The issue of the cursor not showing up in Chrome within a nested contenteditable structure arises when applying CSS after the

Currently, I am coding a HTML document that includes an element with the attribute contenteditable set to true, but this element is wrapped inside a parent element with contenteditable set to false. The HTML structure looks like this: <div contentedita ...

I can't figure out why the callback function for my $.get() request is not being triggered when I send data to the Express

Could anyone help me understand why my callback function is not being called properly? $.get("http://localhost:8080/", msg, function(data) { alert("Data" + data); }); It seems like the server receives the reque ...

Is it accurate to categorize every ajax request (using xmlhttprequest) as a web service request?

Recently, I began incorporating AngularJS with Spring MVC as my backend. I have been utilizing $resource to connect with my backend. Given that this is a restful service and $resource operates using ajax, I find myself questioning: 1) Is ajax solely used ...

The Vue-Apollo V4 composition API from @vue/apollo-composable encountered an error while trying to call it on the login form, resulting in the issue TS2349: "This expression is not callable. Type 'Ref<any>' has no

Being a newcomer in the world of Apollo, I am utilizing Vue composition API along with @vue/apollo-composable version V4 for my vue apollo client. My backend consists of a nodejs server with apollo server. Currently, I am facing an issue on the login page ...

Combating React SetState Race Conditions with the Power of Promise.all

componentDidMount() { Promise.all([OfferCreationActions.resetOffer()]).then( () => { OfferCreationActions.updateOfferCreation('viewOnly', true); OfferCreationActions.updateOfferCreation('loadingOffer', true); ...

What is the best way to convert an array of data into a dataset format in React Native?

Within my specific use case, I am seeking to reform the array structure prior to loading it into a line chart. In this context, the props received are as follows: const data = [26.727, 26.952, 12.132, 25.933, 12.151, 28.492, 12.134, 26.191] The objective ...

Receiving data through a POST request in Node

I am currently working on a project where I need to send an email via a POST request to my node/express server. However, I am facing difficulties in passing the email details through the request and accessing them on the node side. Here is what I have tri ...

Utilizing a variety of shaders on different mesh objects

I am working on applying different shaders to meshes with video textures. Currently, I can only see one shader at a time, but I would like to be able to see both (for example, monochrome and sepia). How can I achieve this? When I comment out one shader, I ...

Using jQuery to retrieve the HTML code for links

I am looking for a way to extract HTML links from a specific div without relying on regular expressions. Here is an example scenario: <div>Please review the links provided in the content. For instance, <a href="http://en.wikipedia.org/wiki/Apple ...

Navigating Angular's Credit Card Input Functionality

I am looking to limit the input capacity to 16 numbers and add a space between each set of 4 numbers. After conducting an extensive search for a credit card input that allows users to enter 16 digits with a " - " or space in between, all results were for ...

Having trouble setting $scope after redirecting to a partial template via routing

Looking to create a website that loads all necessary templates upon the initial visit. Currently, I only have one partial template but plan to add more in the future. Despite having just this one template, I'm struggling with binding the data from my ...

Increment field(s) conditionally while also performing an upsert operation in MongoDB

I need to perform an insert/update operation (upsert) on a document. In the snippet below, there is a syntactical error, but this is what I am attempting to achieve: $inc: { {type=="profileCompletion"?"profileCompletion":"matchNotification"}: 1}, If the ...