postcss-cli | CLI for postcss -
kandi X-RAY | postcss-cli Summary
kandi X-RAY | postcss-cli Summary
CLI for postcss
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Process css .
- get the results of the dependencies to be sent to the console
- Build the CLI configuration .
- process the config file
- Read all input files
- Print error and exit .
- Get the ancestor directories recursively .
- write a string file
- Print a verbose verbose message .
postcss-cli Key Features
postcss-cli Examples and Code Snippets
Community Discussions
Trending Discussions on postcss-cli
QUESTION
Talwind CSS is not working with React. I have installed Tailwind CSS as per the documentation (https://v1.tailwindcss.com/docs/installation) and my code is below.
Can someone help me?
Here is my browser pic of the inspect to understand my problem
Here is my package.json file
...ANSWER
Answered 2022-Feb-06 at 18:40I've looked at your repo: and even though you said you followed the guide, you didn't. The issue boils down to not really following through the documentation properly.
This line is missing in your tailwind.config.js
file, which causes tailwind to fail to detect class usage in all your .js
file:
QUESTION
I'm trying to follow some YT tutorial about Bootstrap 5 with the use of some tools like Sass.
Author of this video in his example at the beginning is testing if his script for compiling Sass code is working.
Here's the screenshot of his work:
I tried to do the same thing and I got an error saying:
Error: Sass variables aren't allowed in plain CSS.
Here's my code:
...ANSWER
Answered 2022-Jan-07 at 15:10What is your file extension? It should be .scss
. => my-style.scss
QUESTION
The goal is to configure a development environment for Tailwindcss v3 that supports @import and the removal of unused custom CSS classes.
I am not using a bundler. The project depends on just HTML, CSS, and JS i.e. no frameworks. If it's important, I use VS Code.
This is what I've tried.
Project's configuration:
...ANSWER
Answered 2021-Dec-31 at 16:33Your intuition is correct. You do not need to run post-cli
. PostCSS will execute once you update your Tailwind command.
You are missing the --postcss
parameter.
Assuming that postcss.config.js is in your project's root, copy this to the script section of your package.json:
"tw": "tailwindcss -i ./src/css/styles.css -o ./css/styles.css --postcss postcss.config.js --watch"
Then from the command line at the project's root, run:
npm run tw
Note: with the above command, Tailwind will not rebuild the output file after the HTML file has been saved. You'll need to edit and save one of the CSS source files to initiate a rebuild. (Perhaps I still have a configuration problem?)
One other item, how are you testing for the removal of unused custom classes?
The mistake I made was just commenting out the HTML utilizing the custom class and then looking at the CSS output to see if the class was removed. But Tailwind (as documented somewhere) won't remove a class if the class appears anywhere in the markup, even in a commented line. If you're testing your build process, rename the class in the markup to anything, and then Tailwind will drop the custom class from the CSS output.
QUESTION
I 've built a react app that runs noermally in dev but when I prod build it the front end fetch requests dont use the proxy I've specified in the package.json file.
fetch request:
...ANSWER
Answered 2021-Dec-19 at 11:41You need to make Nginx pass the calls to your API through to your API container. A common way to do that is to prefix all API requests with /api/, so your /login endpoint becomes /api/login.
If you change your nginx.conf to
QUESTION
I've written a react app with a banch of different urls using component and I'm trying to deploy it using docker. While the main page loads the rest of them don't. When I run npm run build everything works fine so the problem is probably in my Dockerfile. The error I get is 404 Not Found nginx/1.21.4
...ANSWER
Answered 2021-Dec-18 at 13:34My Dockerfile was wrong the correct one is:
QUESTION
I'm attempted to develop a new feature for my blog, that is a Markdown editor for writing articles.
I chosed @tailwindcss/typography
and markdown-it to do that, so this is my whole dependencies:
ANSWER
Answered 2021-Sep-05 at 16:35use react-markdown instead of markdown-it
here is an example:
QUESTION
Auth.onAuthStateChanged is not a function
I have created a web application with React npx create-react-app my-app)
It is a simple application that shows a list of products from a store, from where the user can add more products. Once finished, I have decided that registration by email is mandatory in order to see the content and be able to add products.
I need it to be mandatory to login to access the application.
Since I don't have a lot of Backend experience, I have used Firebase.
I have read information, I have seen examples and finally I have added the necessary code to my App so that when entering it, it is necessary to enter the email and password.
Once I log in, I would enter the main page
I have repeated the steps several times and I always get the same error.
I have looked for examples elsewhere and in this same place, but I cannot solve my problem.
I show my error and some of the files that I create are the cause.
Console Errors:
...ANSWER
Answered 2021-Sep-02 at 07:23You should try importing auth
from firebase.js
and not Firebase module:
QUESTION
I have inherited a React application that uses CSS in JS. This is cumbersome as all of the SCSS is written as a string, making it very difficult to work with as no code hinting or formating by the IDE can be done.
I am used to working with web-pack for these kinds of things, but I don't think it is part of the solution as I can't find a reference to it in the package.json file.
I am trying to switch over to SCSS, but am not quite managing. I am using the following tutorial that claims to work without web-pack:
https://medium.com/programming-sage/react-and-sass-setup-no-webpack-no-bs-a813ac56a9b7
Here is a copy of my package.json:
...ANSWER
Answered 2021-Aug-19 at 04:49Your project is using react-scripts
which comes from create-react-app. CRA uses webpack and works well with SASS.
If you want to change the default webpack configuration you will either need to eject
(not recommended) or use something like react-app-rewired (or similar tool).
QUESTION
I want to compile SCSS files and use autoprefixer. npm run build
compiles the SCSS file to CSS file. Then I can use this finished CSS file for autoprefixer.
But I have a problem with npm run watch
(compiling works). I couldn't find an opportunity to let SASS watch for file changes AND redirect the new file content to autoprefixer.
Here is my package.json
first:
ANSWER
Answered 2021-May-22 at 20:53I solved my problem by using a Gruntfile.js. There I use grunt-contrib-watch which is executing sass and autoprefixer everytime my SCSS file is changed.
Here's my package.json
:
QUESTION
I have the following package.json however on my environment (windows 10/vs code/vagrant homestead php) compile:development only works if I empty my outputted build.css first, then hit save and trigger the watch. Otherwise the css file never changes. This apparently works on somebody else machine (could be a red herring; trust no-one).
...ANSWER
Answered 2021-Apr-08 at 08:36Rewrote the compile scripts as the below to get it to work
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install postcss-cli
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page