982 questions
1
vote
0
answers
50
views
Reuse classes from well-known ontologies adding custom properties?
I have a question regarding ontology design.
I want to reuse the schema:Message class in my ontology. But, I also want to include both schema.org properties and custom properties, related to schema:...
0
votes
1
answer
45
views
How to Reuse a React Component Across Different Design Systems (Cloudscape to Material) While Keeping Component Logic Intact?
Question:
I have a React component in Package A that contains business logic and UI hooks, running on the Cloudscape Design System. This component is consumed by Package B (also Cloudscape). Now, I ...
0
votes
0
answers
71
views
How to reuse GitHub Action workflows across instances
I use predefined workflows in my repositories that I keep in a common repository on my org.
We use multiple GH Enterprise instances and I would like to reuse these workflow also on the other instance ...
0
votes
1
answer
112
views
How to pass the component as a component prop in Qwik
In react we can pass the component as a component property. For example
Link to the codesandbox.
interface IButtonProps {
icon?: React.ComponentType;
children: React.ReactNode;
}
const Button = ...
0
votes
1
answer
70
views
For using the files in other folder outside of dags, inside dags/ folder in apache airflow
I have the structure of folder as:
folder_structure
I want to use files which are present in deps folder in the dag files present in dags folder, how to do that?
Can someone please help me with this
I ...
0
votes
1
answer
92
views
Reduce Spyder plot memory usage
I want to plot an array many times in a row as it changes on Spyder.
Every time I do this, it is in a new plot. After many iterations the system stops, I presume because it is out of memory.
How do I &...
2
votes
2
answers
266
views
How can I reuse a boost::asio socket, received from acceptor.async_accept call in coroutine environement?
I'm new to Boost::Asio and have encountered a problem with asio::ip::tcp::socket storage. I receive a server side socket from an asio::ip::tcp::acceptor.async_accept() call and store it in allocated ...
-1
votes
1
answer
64
views
Reuse overloaded method in python class with most parameters
I have LCD class which is run by micropython on raspberry pi pico which i initialise like this:
class Lcd:
def __init__(self, width, height, channel, sdaPin, sclPin, contrast):
from time ...
0
votes
1
answer
61
views
Print the greatest number in assembly programming
Trying to print the greatest number (a & b) by using the below assembly code. But it is printing the "first" (Welcome) message only. I just want to print the "second" (i.e ...
0
votes
0
answers
49
views
Can I use single Blazor application as a module for different applications?
I have Blazor application. I want to use it with different databases. I could achieve it by hardcoding appName. This is program.cs
Dictionary<string, string> connStrs = new Dictionary<string, ...
2
votes
2
answers
76
views
JS Classes with same arguments
I have a JS Class and would like to be able to "reuse" it without running the constructor multiple times when I create the same classe with identical parameters.
The use case is for example ...
2
votes
1
answer
190
views
How to write a reusable DB transaction wrapper?
I need to write a reusable function where part of it can be run before and after its invoked.
For example:
isNewTnx, rollback, beginErr := DbConnectionManager.Begin(req)
if beginErr != nil {
...
1
vote
1
answer
254
views
Reusable/Shared Angular material autocomplete returns null even after selection even with ControlValueAccessor
I have implemented a shared/reusable angular material autocomplete, which uses values from a server returned as objects. I can integrate it into other components. However, if I use my component:
<...
1
vote
1
answer
371
views
List unreachable servers in Ansible using a reusable playbook
I'm able to list unreachable servers using the below Ansible playbook:
---
- name: "Play 1-Find the details here {{ source_host }} & {{ dest_host }}"
hosts: localhost
...
0
votes
1
answer
104
views
Can a DataTemplate be reused by binding it to different properties with the same data type?
I use a DataGrid with several columns of the same data type. I want to use a DataGridTemplateColumn for the columns and define a DataTemplate for the CellTemplate and one for the CellEditingTemplate.
...
0
votes
0
answers
38
views
VB.NET VS2017 net 4.6.1 moving AspNetIdentity 2.2.2 code from website project to reusable DLL since I have 80+ web sites to convert
Using package Microsoft.AspNet.Identity.Core.2.2.2\lib\net45\Microsoft.AspNet.Identity.Core.dll
The following IntranetSecurity.vb code works when called within the website code base.
Dim manager = ...
0
votes
0
answers
35
views
Does basic Python have any equivalent to extending Django templates?
What I mean is that with Django templates, you can create a quite long file A, have a couple of "block" elements in it that can be extended in other files, and then you can create files B ...
0
votes
1
answer
609
views
openSSL TLSv1_3 session resumption
I am using openssl 3.2.0 and I am creating a FTP-Client. Everything works fine when using only TLSv1_2, but the needed session-resumption does not work with TLSv1_3 when connecting with File-Zilla FTP ...
0
votes
1
answer
150
views
No overload matches this call in Next.js/Typescript
I got this type error. No overload matches this call.
Overload 1 of 3, '(props: PolymorphicComponentProps<"web",
FastOmit<Omit<AnchorHTMLAttributes, keyof
InternalLinkProps> &...
0
votes
1
answer
416
views
Component reusable issue in Angular
I am new to angular reusable components and am unsure how to reuse the component once it's built. I have 3 components parent, container and reusable components.
parent.component.ts
...
0
votes
1
answer
94
views
Is it bad to use an instance of an operator to access child class variables from a parent reference?
I have a class, e.g., Person, having some parameters, e.g., name and age.
Now I want to add some other parameters, e.g., employment. These new parameters are only useful to one mode of the ...
-2
votes
1
answer
153
views
Using the same entity to process data of different types - are the new VHDL 2008 features usable for that?
Many times I created VHDL blocks that may handle data of different types.
One example is a heap stream data sorter - https://opencores.org/projects/heap_sorter , another one is the data concentrator ...
0
votes
0
answers
28
views
makefile doesn't reuse variables as expected
Makefile
SRC := a
first: $(SRC)
@echo $(SRC)
@echo "$@ $<"
SRC := b
second: $(SRC)
@echo $(SRC)
@echo "$@ $<"
Why does it echo "b"...
0
votes
1
answer
56
views
How to refactor two xml files in Android into a reusable component?
I have two different xml files in an Android project that are very similar -- they both specify an ImageView and a TextView -- the only difference is that they have a different text and image source ...
0
votes
1
answer
115
views
Trouble making components reusable in Angular
I've been trying to make a custom Material Angular Table component reusable. The component will have the ability to expand rows to display a details component.
My first idea was to content project the ...
0
votes
2
answers
951
views
Trying to build a dynamic stepper inside material dialog with reactive forms for a reusable 'automated' assistant component
So I'm trying to build an assistant that shows different steps depending on what data it received. That way I can reuse it for many different flows for every user type (who require individual steps ...
1
vote
1
answer
219
views
How to generate REUSE/SPDX info for a git repo
Intro
The REUSE tool from the REUSE project by the Free Software Foundation Europe
allows to add, maintain and extract detailed copyright and licensing info on a fine-grained scale,
and it does that ...
0
votes
2
answers
81
views
Is it possible to override the implementation inside the generated actionPerformed in java?
I'm using a NetBeans as my IDE for Java. I have class called NewSchoolYearDialog extended by JDialog:
The purpose of that Save button in the image above is to insert a school year into a database.
...
0
votes
1
answer
442
views
How to reuse code/functionality from multiple Spring Boot applications?
I'm developing multiple applications (API's) with Spring Boot and some of them are only used by some specific clients. The problem is that I'm having to duplicate code and functionalities between ...
0
votes
1
answer
55
views
Using a prop in the path of a styled component
I've got a couple of styled-components with paragraphs that use the same exact css-stylings, these stylings come from an imported data object. I'm trying to figure out what would be the best way to be ...
-1
votes
1
answer
103
views
How can I make this function reusable " foreach loop" in selenium c#?
foreach (Residency residency in test.Residencies)
{
if (residency.TestGuid == testGuid)
{
if (requiredResidency == null)
...
1
vote
0
answers
457
views
Reusing Response DTO similar to Entity, Using Typescript's Pick Util type
I am a backend developer doing server development using nestJs.
I have a simple but perhaps difficult question.
This question arose from the following stackoverflow answer.
stackOverflow
If the reason ...
0
votes
1
answer
70
views
How to abstract repetitive React code pattern into a reusable component or object?
Don't spend too much time analyzing this section, just pay attention to the similarities of each group.
// LOADING ALL VENDORS
const [loadingAllVendors, setLoadingAllVendors] = useState<boolean>(...
0
votes
1
answer
276
views
Feature Store: Patterns for reusing the same features across different models
I'm looking to use a feature store to optimize feature reuse across many different models.
Example:
I have 10 different models that use the same 2 feature sets (e.g.: 2 datasets of features without ...
0
votes
0
answers
31
views
UserControl is way less performant hen declaring it in the XAML file
I've been creating a WPF application, which contains a ListView, bound to a collection of strings. For each string it'll display the value and a button, containing an image and some text. To keep my ...
0
votes
0
answers
182
views
Using or partially re-using an Angular service inside a React micro-frontend
I'm working on an application that uses single-spa to integrate both Angular and React Micro-frontends onto an Angular host page.
React micro frontends have recently been introduced into the app where ...
0
votes
1
answer
565
views
Write a modular C program that returns optimal number of coins for a chosen amount in a chosen currency
Write a modular solution (C program) that will accept as input an amount of money (in cents) in a certain currency and return the optimal number of coins in that currency.
The amount of money entered ...
0
votes
1
answer
66
views
A reusable component that emits a value for the first subscriber when used multiple times
I have created a reusable Angular component as shown below.
export enum ESwitchType {
switch = 'switch',
radio = 'radio',
checkbox = 'checkbox',
}
export type TValidSize = 'sm' | 'md' | '...
-1
votes
1
answer
70
views
Why is my generic map function returning undefined? [closed]
I have an array of car objects:
[
{
id: 1,
make: "Honda",
model: "Civic",
style: "Coupe"
},
{
id: 2,
make: "Toyota",
model: &...
0
votes
1
answer
195
views
I'd like to make my website's sidebar a reusable component, but I'm not sure how
I have a blog with many pages, and more are being added all the time because it's still under construction. The sidebar changes frequently, and manually modifying all of the sidebars for all of the ...
4
votes
2
answers
3k
views
Is it okay to have a bunch of incomplete Stripe payment intents?
I am implementing the Stripe payment platform using JavaScript and the PHP SDK.
I don't have any issues with the implementation itself, but I am not sure whether I have to reuse an existing ...
-1
votes
1
answer
51
views
How to Make a Reusable Function that Removes Duplicates
I am trying to make a function as re-usable as possible.
I have a JSON file containing "products" for now.
export let productList = [
{
id: 0,
productName: "Men's ...
0
votes
0
answers
265
views
Copy content of Word range to variable for later use?
I have a Word document that has a checkbox. When the checkbox is clicked (unchecked) I select a range, copy it into a Range variable and then delete the original range. If the checkbox is clicked ...
-1
votes
1
answer
53
views
ReUse of class component in react
Im new to react and in the application im working im using a class component Summary
class SummaryList extends React.Component {
//code for the summarylist component here
}
class ...
1
vote
0
answers
508
views
How to set parameters for included T4 templates?
If I have a reusable T4 template, how can I set parameters when recalling it?
Consider these two example files...
Hello.t4:
<#@ parameter type="System.String" name="Name" #>
...
0
votes
1
answer
82
views
How to use same JavaScript program multiple times on same website
I am working on my Portfolio project and for that I have made a International country code selector program for my phone number field. but the problem I'm facing right now is that I have two forms in ...
0
votes
1
answer
329
views
modal bottom sheet reusable class missing "State build" method
I am trying to create a custom bottom sheet class to be re-usable, but it gives me the error of missing "State build" method. I know that I may include the @override method, but I have ...
1
vote
2
answers
68
views
Is there a way I can reuse part of my code that does the same thing but access different attributes of a class in Java?
So I was doing a program there's supposed to verify if when cut, a triangle can produce two new triangles, I did all the logic and the code works just as it is supposed to, however as I was doing I ...
0
votes
2
answers
218
views
How to access self variable array type?
I have defined subnetIds in serverless:
enviroment:
subnetIds:
- subnet1
- subnet2
Now, at function define enviroment, I want to get each subnet like that:
environment:
...
0
votes
1
answer
74
views
Reactjs Component Reusability [closed]
I am working on a project in react. Where most of the data on different tabs have a table. So I design the "TableItems" component and passed the data according to the component. Right now ...