Fourth_quarter
Fourth_quarter
KPCKevin Powell - Community
Created by Fourth_quarter on 3/19/2024 in #front-end
Anyone know how to use yarn generate for react components? My Google search is burning time. Thanks
Just trying to create a component. My Google search is burning time. Thanks
2 replies
KPCKevin Powell - Community
Created by Fourth_quarter on 2/6/2024 in #front-end
How to target the div with the classname "from-sections"
I am trying to reduce the margin-bottom on that element. The code pen doesn't work, but it holds the code. As you will see. I have already tried .form-sections:last-child, and I also tried :last-of-type. No luck! https://codepen.io/bonesdupes/pen/bGZKOwj
7 replies
KPCKevin Powell - Community
Created by Fourth_quarter on 11/15/2023 in #front-end
Struggling with my investigation methods a bit.
Would someone indicate where in this documentation it explains that the Boolean "method" will return only the truthy values please? So if I use it in the following code it returns the number of truthy values in array r. It does what it does but I need to understand why it doesn't return all truth/falsey values and only the truthy ones. Now I'm a bit more confused because I'm not sure if this question even makes sense...
r.filter(Boolean).length
r.filter(Boolean).length
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean (edited)
23 replies
KPCKevin Powell - Community
Created by Fourth_quarter on 10/20/2023 in #back-end
Trying to understand if I always need to identify commonjs or module?
I have the following package.json file and do not see a type key, but they are using es module import statement. They also import json files without using createRequire(). How is this possible? Add to that that they are using require statements as well...how? var os = require('os'); in index.js below
{
"name": "incoming-mobile-event-service",
"version": "1.0.15",
"description": "ES6 RESTful Express API for SOME SERVICE",
"main": "dist",
"scripts": {
},
"eslintConfig": {
"extends": "eslint:recommended",
"parserOptions": {
"ecmaVersion": 7,
"sourceType": "module"
},
"env": {
"node": true,
"es6": true
},
"rules": {
"no-console": 1,
"no-unused-vars": 1
}
},
"repository": "https://gitlab.com/COMPANYDev/COMPANY-DEPT/SOME-service",
"author": "COMPANY IT",
"dependencies": {
},
"devDependencies": {
}
}
{
"name": "incoming-mobile-event-service",
"version": "1.0.15",
"description": "ES6 RESTful Express API for SOME SERVICE",
"main": "dist",
"scripts": {
},
"eslintConfig": {
"extends": "eslint:recommended",
"parserOptions": {
"ecmaVersion": 7,
"sourceType": "module"
},
"env": {
"node": true,
"es6": true
},
"rules": {
"no-console": 1,
"no-unused-vars": 1
}
},
"repository": "https://gitlab.com/COMPANYDev/COMPANY-DEPT/SOME-service",
"author": "COMPANY IT",
"dependencies": {
},
"devDependencies": {
}
}
index.js
import bodyParser from 'body-parser';
import express from 'express';
import validator from 'express-validator';
import http from 'http';
import morgan from 'morgan';
import swagger from 'swagger-ui-express';

import config from './config.json';
import swaggerConfig from './config/swagger.json';
import winston from './config/winston';
import tracing from './config/tracing';
import {
defaultNotFoundHandler,
defaultErrorHandler,
} from './controllers/error.controller';
import { checkDatabaseConnections } from './config/health';

var os = require('os');
import bodyParser from 'body-parser';
import express from 'express';
import validator from 'express-validator';
import http from 'http';
import morgan from 'morgan';
import swagger from 'swagger-ui-express';

import config from './config.json';
import swaggerConfig from './config/swagger.json';
import winston from './config/winston';
import tracing from './config/tracing';
import {
defaultNotFoundHandler,
defaultErrorHandler,
} from './controllers/error.controller';
import { checkDatabaseConnections } from './config/health';

var os = require('os');
1 replies
KPCKevin Powell - Community
Created by Fourth_quarter on 7/31/2023 in #front-end
Issue with centering button text
I have a button with the following direct styling. The internal text will not center and I have tried various methods, but the goal is to align the internal text both vertical and horizontal. TRIED: padding: 0; padding: auto; Here is the entire code...https://codesandbox.io/s/ict-birthday-list-fdh3kc?file=/index.html
button.list-record-button {
height: 9%;
width: 75%;
margin: 2rem auto;
line-height: 1rem;
text-align: center;
}
button.list-record-button {
height: 9%;
width: 75%;
margin: 2rem auto;
line-height: 1rem;
text-align: center;
}
17 replies