CN111158680A - Page construction method, device, equipment and storage medium - Google Patents
Page construction method, device, equipment and storage medium Download PDFInfo
- Publication number
- CN111158680A CN111158680A CN201911373566.8A CN201911373566A CN111158680A CN 111158680 A CN111158680 A CN 111158680A CN 201911373566 A CN201911373566 A CN 201911373566A CN 111158680 A CN111158680 A CN 111158680A
- Authority
- CN
- China
- Prior art keywords
- target
- page
- functional module
- module group
- modified
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/30—Creation or generation of source code
- G06F8/38—Creation or generation of source code for implementing user interfaces
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The embodiment of the application discloses a page construction method, a device, equipment and a storage medium, wherein the method comprises the following steps: building at least two pages based on a configuration file group and a function module group corresponding to the at least two pages; when a page construction instruction is acquired, determining a target page to be constructed from at least two pages based on page identification information in the page construction instruction; acquiring a target function module group corresponding to a target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page; and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page. Therefore, when a project comprising a plurality of pages is improved, only the page needing to be modified is reconstructed, and all the pages do not need to be integrally constructed, so that the construction time can be greatly reduced, and the development efficiency can be improved.
Description
Technical Field
The present application relates to the field of web platform development, and in particular, to a method, an apparatus, a device, and a storage medium for page construction.
Background
The current front-end project is increasingly used in various frameworks, libraries, new language characteristics and advanced modular code organization forms, but the front-end code usually runs in various environments and systems, and needs to process complex compatibility and solve various potential performance problems. A complex building process is experienced from the source code to the code running on-line.
As items expand, functions increase, and the number of pages and the amount of code for a single page both increase dramatically. Therefore, in the development process of the page, the construction process takes longer and longer time, the normal development process is influenced, and a large amount of time is spent to wait for the completion of the construction of all the pages before continuing the subsequent verification process. Therefore, projects with long maintenance time can seriously affect the development efficiency of the projects.
Disclosure of Invention
In order to solve the foregoing technical problem, embodiments of the present application are intended to provide a method, an apparatus, a device, and a storage medium for page construction.
The technical scheme of the application is realized as follows:
in a first aspect, a method for constructing a page is provided, where the method includes:
building at least two pages based on a configuration file group and a function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
when a target page construction instruction is acquired, determining a target page to be constructed from the at least two pages based on target page identification information in the target page construction instruction;
acquiring a target function module group corresponding to the target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page;
and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page.
In the foregoing solution, the modifying at least a part of the functional modules in the functional module group to obtain the functional module group after the target page is modified includes: selecting the at least part of the functional modules needing to be modified from the target functional module group; modifying at least part of the functional modules to obtain the modified functional module group; or deleting at least part of the functional modules from the target functional module group to obtain the modified functional module group.
In the above scheme, the method further comprises: establishing at least one new functional module for the target page; and adding the at least one new functional module into the target functional group to obtain the modified functional module group.
In the foregoing solution, the obtaining of the target function module group corresponding to the target page includes: acquiring a target function module group corresponding to the target page based on the corresponding relation between the at least two pages and the function module group; or acquiring at least one functional module indication message; determining at least one functional module indicated by the at least one functional module indication information; and utilizing the determined at least one functional module to form the target functional module group.
In the foregoing solution, the reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain a modified target page includes: acquiring a target configuration file group corresponding to the target page; selecting a first configuration file matched with a first functional module from the target configuration file group; wherein, the first functional module is any one functional module in the modified target functional module group; and constructing a page by using each functional module in the modified target functional module group and the matched configuration file thereof to obtain a modified target page.
In the above solution, the configuration file group includes at least one of the following configuration files: public resources, entry file construction, html construction template and target directory.
In a second aspect, there is provided a development-based build apparatus, the apparatus comprising:
the building unit is used for building at least two pages based on the configuration file group and the function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
the determining unit is used for determining a target page to be constructed from the at least two pages based on target page identification information in a target page construction instruction when the target page construction instruction is acquired;
the acquisition unit is used for acquiring a target function module group corresponding to the target page;
the modification unit is used for modifying at least part of the functional modules in the target functional module group to obtain a functional module group after the target page is modified;
the constructing unit is further configured to reconstruct the target page based on the target configuration file group corresponding to the target page and the modified target function module group, so as to obtain a modified target page.
In the foregoing solution, the modifying unit is specifically configured to select the at least part of the functional modules that need to be modified from the target functional module group; modifying at least part of the functional modules to obtain the modified functional module group; or, the modifying unit is specifically configured to delete at least part of the functional modules from the target functional module group, so as to obtain the modified functional module group.
In the above scheme, the apparatus further comprises: the new building unit is used for building at least one new functional module for the target page; and the adding unit is used for adding the at least one new functional module into the target functional group to obtain the modified functional module group.
In the above scheme, the obtaining unit is specifically configured to obtain a target function module group corresponding to the target page based on a correspondence between the at least two pages and the function module group; or, the obtaining unit is specifically configured to obtain at least one function module indication information; determining at least one functional module indicated by the at least one functional module indication information; and utilizing the determined at least one functional module to form the target functional module group.
In the above scheme, the construction unit is specifically configured to obtain a target configuration file group corresponding to the target page; selecting a first configuration file matched with a first functional module from the target configuration file group; wherein, the first functional module is any one functional module in the modified target functional module group;
and constructing a page by using each functional module in the modified target functional module group and the matched configuration file thereof to obtain a modified target page.
In the above solution, the configuration file group includes at least one of the following configuration files: public resources, entry file construction, html construction template and target directory.
In a third aspect, an apparatus for page construction is provided, including: a processor and a memory configured to store a computer program operable on the processor, wherein the processor is configured to perform the steps of the aforementioned method when executing the computer program.
In a fourth aspect, a computer-readable storage medium is provided, on which a computer program is stored, wherein the computer program, when executed by a processor, implements the steps of the aforementioned method.
By adopting the technical scheme, at least two pages are constructed based on the configuration file group and the functional module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page; when a page construction instruction is acquired, determining a target page to be constructed from at least two pages based on page identification information in the page construction instruction; acquiring a target function module group corresponding to a target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page; and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page. Therefore, when a project comprising a plurality of pages is improved, only the page needing to be modified is reconstructed, and all the pages do not need to be integrally constructed, so that the construction time can be greatly reduced, and the development efficiency can be improved.
Drawings
FIG. 1 is a schematic flow chart of a page construction method in an embodiment of the present application;
FIG. 2 is a flowchart of a page construction method according to an embodiment of the present disclosure;
FIG. 3 is a schematic diagram of a composition structure of a page building device in an embodiment of the present application;
fig. 4 is a schematic structural diagram of a page building apparatus in an embodiment of the present application.
Detailed Description
So that the manner in which the features and elements of the present embodiments can be understood in detail, a more particular description of the embodiments, briefly summarized above, may be had by reference to embodiments, some of which are illustrated in the appended drawings.
An embodiment of the present application provides a page construction method, fig. 1 is a schematic flow chart of the page construction method in the embodiment of the present application, and as shown in fig. 1, the page construction method may specifically include:
step 101: building at least two pages based on a configuration file group and a function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
step 102: when a target page construction instruction is acquired, determining a target page to be constructed from the at least two pages based on target page identification information in the target page construction instruction;
step 103: acquiring a target function module group corresponding to the target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page;
step 104: and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page.
Here, the execution subject of steps 101 to 104 may be a processor of the page building apparatus.
Because the front-end function is usually divided by taking a page as a carrier, usually one page represents a part of relatively independent functions; before the development and construction process is carried out, firstly, taking a page as granularity, extracting public resources, construction entry files (entry), html construction templates (html Webpack plug), target directories and the like required by the page, and forming a configuration file group; generally, each page includes at least one function, and the function modules are divided according to the page functions to obtain at least one function module, that is, each page corresponds to at least one function module, and the at least one function module forms a function module group of the page; each functional module is used for realizing partial functions of the corresponding page.
When constructing at least two pages, firstly acquiring a configuration file group and a function module group corresponding to the at least two pages, and then completing the construction process of the at least two pages based on a webpack construction tool; each page has a corresponding configuration file group and a corresponding function module group.
In practical application, the page construction instruction may include page identification information corresponding to a page to be reconstructed (i.e., a target page), and a specific target page may be determined through the page identification information; storing the corresponding relation between at least two pages in a project and corresponding page identification information thereof in a database; and when the target page construction instruction is acquired, inquiring the target page to be constructed from the database according to the target page identification information contained in the target page construction instruction.
Specifically, the method for determining the page to be reconstructed based on the page construction instruction includes: a page construction instruction determines a page needing to be reconstructed, which means that when a target page construction instruction is obtained, a target page corresponding to the target page construction instruction is inquired from a database; or, one page building instruction determines a plurality of pages to be reconstructed, and one page building instruction may include a plurality of lunar surface identification information for indicating the plurality of pages to be reconstructed.
Here, the page identification information may also be used to indicate a functional module of the target page that needs to be reconstructed, or the page construction instruction may also separately include indication information for indicating a functional module of the target page that needs to be reconstructed.
Illustratively, in the front-end project development, a construction process is quickly started through an npm script command, page identification information is transmitted in a "- -" mode, and the transmitted page identification information is acquired through a yargs command and is used for indicating a target page and a functional module of the target page, which needs to be reconstructed.
For example: the format of the page identification information is communicated by the npm command: npm run dev- - -m uc ac, and obtaining the page identification information through yargs command; the page identification information comprises-m parameters for indicating a target page, and the page identification information also comprises uc module parameters and ac module parameters for reconstructing a uc module and an ac module of the target page.
In some embodiments, the obtaining of the target function module group corresponding to the target page includes: acquiring a target function module group corresponding to the target page based on the corresponding relation between the at least two pages and the function module group; or acquiring at least one functional module indication message; determining at least one functional module indicated by the at least one functional module indication information; and utilizing the determined at least one functional module to form the target functional module group.
In practical application, the functional module corresponding to the target page to be obtained can be obtained in the following two ways:
the method comprises the steps that at least two pages are needed for forming a front-end project, each page corresponds to a corresponding functional module group, the relationship between the at least two pages of one front-end project and the corresponding functional module group of each page is stored in a database, when a target page construction instruction is obtained, a target page is obtained according to the construction instruction, and then a target functional module group corresponding to the target page is obtained from the database according to the target page;
or determining at least one functional module based on the at least one functional module indication information; and forming a target function module group corresponding to the target page based on at least one function module.
In some embodiments, the modifying at least a part of the functional modules in the functional module group to obtain the functional module group after the target page is modified includes: selecting the at least part of the functional modules needing to be modified from the target functional module group; modifying at least part of the functional modules to obtain the modified functional module group; or deleting at least part of the functional modules from the target functional module group to obtain the modified functional module group.
In practical application, when a target page function needs to be modified according to project requirements, firstly, a target function module group corresponding to the target page is obtained, then, a modified specific function module is selected from the target function module group according to the function of the target page, and the determined modified function module is modified to obtain a group of modified function module groups; or, deleting unnecessary functional modules in the target functional module group according to project requirements to obtain a group of modified functional module groups.
In some embodiments, the method further comprises: establishing at least one new functional module for the target page; and adding the at least one new functional module into the target functional group to obtain the modified functional module group.
In practical application, at least one new functional module needs to be established for a target page based on the new functional requirements of the project; and adding the reestablished at least one new functional module into the original target functional group to obtain the modified functional module group.
In some embodiments, the reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain a modified target page includes: acquiring a target configuration file group corresponding to the target page; selecting a first configuration file matched with a first functional module from the target configuration file group; wherein, the first functional module is any one functional module in the modified target functional module group; and constructing a page by using each functional module in the modified target functional module group and the matched configuration file thereof to obtain a modified target page.
In practical application, when a target page is modified, a target configuration file group and a target function module group of the target page are respectively obtained; the target function module group comprises at least one function module, each function module is matched with a plurality of configuration files, namely the target configuration files comprise a plurality of configuration files matched with each function module group, a first configuration file matched with a first function module is selected from the target configuration file group, and the first function module is any one function module in the target page function module group, namely the configuration file matched with each function module is selected; according to the requirement of the target page in the project, selecting at least one functional module to be modified from the target functional module group, carrying out functional modification on the code of the at least one functional module, and matching each functional module in the modified functional module group with a plurality of corresponding configuration files after the modification is finished; the target configuration file group comprises a plurality of configuration files matched with a plurality of functional modules; and finally, constructing the selected function module group and the matched corresponding configuration file group by using a webpack construction tool to obtain a modified target page.
By adopting the technical scheme, at least two pages are constructed based on the configuration file group and the functional module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page; when a page construction instruction is acquired, determining a target page to be constructed from at least two pages based on page identification information in the page construction instruction; acquiring a target function module group corresponding to a target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page; and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page. Therefore, when a project comprising a plurality of pages is improved, only the page needing to be modified is reconstructed, and all the pages do not need to be integrally constructed, so that the construction time can be greatly reduced, and the development efficiency can be improved.
An embodiment of the present application provides a method for constructing a page, fig. 2 is a flowchart of a specific implementation method for constructing a page in the embodiment of the present application, and as shown in fig. 2, the page construction method may specifically include:
step 201: starting construction;
step 202: starting a construction process through an npm script command;
specifically, the construction process is started through npm scripts, and page identification information is transmitted in a "- -" mode; for example: and npm run dev- - -m uc ac, wherein the page identification information comprises-m parameters for indicating a target page, and the page identification information also comprises uc module parameters and ac module parameters, and is used for reconstructing a uc module and an ac module of the target page.
Step 203: acquiring page identification information through a yargs command;
and acquiring a corresponding specific page, a uc functional module and an ac functional module which need to be modified through a yargs command, and modifying codes of the uc module and the ac module according to the functional requirements of the project.
Step 204: matching a corresponding configuration file group to the uc module by the construction device based on webpack;
specifically, matching a corresponding configuration file group for the uc module in the webpack construction device; the target configuration file group comprises a plurality of configuration files matched with the plurality of functional modules. The configuration file includes: public resources, a constructed entry file (entry), an html construction template (html Webpack plug), a target directory and the like; since the configuration file sets are mainly based on the two configuration file sets of the building entry file (entry) and the html building template (html Webpack plug), only the two configuration file sets of the selected building entry file (entry) and the html building template (html Webpack plug) are shown in fig. 2.
Step 205: matching a corresponding configuration file group to the ac module by the construction device based on webpack;
specifically, matching a plurality of corresponding configuration files for the ac module in the webpack construction device; the target configuration file group comprises a plurality of configuration files matched with the plurality of functional modules.
Step 206: matching a plurality of corresponding configuration files for other unmodified modules of the target page based on the webpack construction device;
specifically, matching a plurality of corresponding configuration files for other unmodified modules of the target page in the webpack construction device; the target configuration file group comprises a plurality of configuration files matched with the plurality of functional modules.
Step 207: construction was done based on webpack.
Specifically, a plurality of configuration files corresponding to the modified functional modules and the unmodified functional modules in the target page are selected and matched, the configuration required by the final webpack construction is assembled, the construction process of the target page is finally completed, and the required html target page and the static resources in the target page are obtained.
Illustratively, the whole front-end application has 100 pages, and the original construction mode is to construct the 100 pages in full, however, generally, only the function of one page is modified at the same time, that is, only the code of the one page needs to be constructed; after the above improvement, the time taken for the improved solution is probably considered to be 1/100 originally constructed in full amount, compared with the technical solution constructed in full amount.
To this end, a time test is made to verify the inference, namely: in an online project with 10 pages, the process of actually developing one page function is obtained, the original hot updating time is about 105000ms, the improved time is about 1000ms, and the result of the inference is verified to be correct.
The following is a detailed description of the page construction process of webpack.
The webpack construction runs in a node.js environment, and the configuration file of the webpack follows CommonJS specification, and the webpack.config.js derives an Object (or derives a Function or derives a Promise Function, and also derives an array containing multiple configurations). Webpack starts with an entry file, identifies modular import statements in the source code, recursively finds all dependencies, and packs the entry file and all dependencies into a single file (i.e., a chunk), which is called modular packing.
Among them, six core concepts are involved:
entry, which is the first step in the construction of the webpack implementation, can be understood as input.
Module, all modules in webpack, one Module is a file. Webpack recursively finds all dependent modules from Entry.
Chunk, code block, a Chunk is composed of a plurality of modules, which are used for code merging and splitting.
The Loader is used for converting the original content of the module into new content according to the requirement; the method is used for compiling, converting and loading module files, configuring in a module.rules array, and telling webpack which loaders are used for loading and converting when encountering which files; the Loader may also specify an option parameter by querystring or object.
Plugin, an extension plug-in, injects extension logic at specific times during the webpack construction process to alter or optimize the construction results.
Output, final result obtained after a series of processing of the source code in webpack.
The specific construction process for webpack:
after the webpack is started, recursively parsing all modules that the Entry depends on is started from the Entry, and when finding a Module, performing corresponding conversion processing according to Loader rules configured in modules. Therefore, a Chunk is the result of the merge of an Entry and all its dependent modules. Finally webpack will convert all chunks into file Output. In the whole construction process, the webpack executes the logic defined in the plug in at the right time, thereby completing the optimization task of the plug in plug-in.
An embodiment of the present application further provides a page constructing apparatus, and as shown in fig. 3, the apparatus includes:
a building unit 301, configured to build at least two pages based on a configuration file group and a function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
a determining unit 302, configured to determine, when a target page construction instruction is obtained, a target page to be constructed from the at least two pages based on target page identification information in the target page construction instruction;
an obtaining unit 303, configured to obtain a target function module group corresponding to the target page;
a modifying unit 304, configured to modify at least a part of the function modules in the target function module group, so as to obtain a function module group after the target page is modified;
the constructing unit 301 is further configured to reconstruct the target page based on the target configuration file group corresponding to the target page and the modified target function module group, so as to obtain a modified target page.
In some embodiments, the modifying unit 304 is specifically configured to select the at least part of the functional modules that need to be modified from the target functional module group; modifying at least part of the functional modules to obtain the modified functional module group;
or, the modifying unit is specifically configured to delete at least part of the functional modules from the target functional module group, so as to obtain the modified functional module group.
In some embodiments, the new creating unit is configured to create at least one new functional module for the target page; and the adding unit is used for adding the at least one new functional module into the target functional group to obtain the modified functional module group.
In some embodiments, the obtaining unit 303 is specifically configured to obtain, based on the correspondence between the at least two pages and the functional module group, a target functional module group corresponding to the target page;
or, the obtaining unit 303 is specifically configured to obtain at least one piece of function module indication information; determining at least one functional module indicated by the at least one functional module indication information; and utilizing the determined at least one functional module to form the target functional module group.
In some embodiments, the constructing unit 301 is specifically configured to obtain a target profile group corresponding to the target page;
selecting a first configuration file matched with a first functional module from the target configuration file group; wherein, the first functional module is any one functional module in the modified target functional module group;
and constructing a page by using each functional module in the modified target functional module group and the matched configuration file thereof to obtain a modified target page.
In some embodiments, the set of profiles includes at least one of the following profiles: public resources, entry file construction, html construction template and target directory.
By adopting the technical scheme, at least two pages are constructed based on the configuration file group and the functional module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page; when a page construction instruction is acquired, determining a target page to be constructed from at least two pages based on page identification information in the page construction instruction; acquiring a target function module group corresponding to a target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page; and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page. Therefore, when a project comprising a plurality of pages is improved, only the page needing to be modified is reconstructed, and all the pages do not need to be integrally constructed, so that the construction time can be greatly reduced, and the development efficiency can be improved.
An embodiment of the present application further provides a page building device, and as shown in fig. 4, the page building device includes: a processor 401 and a memory 402 configured to store a computer program operable on the processor; the processor 401, when running the computer program in the memory 402, realizes the following steps:
building at least two pages based on a configuration file group and a function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
when a target page construction instruction is acquired, determining a target page to be constructed from the at least two pages based on target page identification information in the target page construction instruction;
acquiring a target function module group corresponding to the target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page;
and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page.
In some embodiments, the processor 401, when executing the computer program in the memory 402, implements the following steps: the modifying at least part of the functional modules in the functional module group to obtain the functional module group after the target page is modified includes:
selecting the at least part of the functional modules needing to be modified from the target functional module group; modifying at least part of the functional modules to obtain the modified functional module group;
or deleting at least part of the functional modules from the target functional module group to obtain the modified functional module group.
In some embodiments, the processor 401, when executing the computer program in the memory 402, implements the following steps: establishing at least one new functional module for the target page;
and adding the at least one new functional module into the target functional group to obtain the modified functional module group.
In some embodiments, the processor 401, when executing the computer program in the memory 402, implements the following steps: the acquiring of the target function module group corresponding to the target page includes:
acquiring a target function module group corresponding to the target page based on the corresponding relation between the at least two pages and the function module group;
or acquiring at least one functional module indication message; determining at least one functional module indicated by the at least one functional module indication information; and utilizing the determined at least one functional module to form the target functional module group.
In some embodiments, the processor 401, when executing the computer program in the memory 402, implements the following steps: reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain a modified target page, including:
acquiring a target configuration file group corresponding to the target page;
selecting a first configuration file matched with a first functional module from the target configuration file group; wherein, the first functional module is any one functional module in the modified target functional module group;
and constructing a page by using each functional module in the modified target functional module group and the matched configuration file thereof to obtain a modified target page.
In some embodiments, the set of profiles includes at least one of the following profiles: public resources, entry file construction, html construction template and target directory.
Of course, in actual practice, the various components in the electronic device are coupled together by a bus system 403, as shown in FIG. 4. It will be appreciated that the bus system 403 is used to enable communications among the components connected. The bus system 403 includes a power bus, a control bus, and a status signal bus in addition to a data bus. But for clarity of illustration the various buses are labeled as bus system 403 in figure 4.
In practical applications, the processor may be at least one of an Application Specific Integrated Circuit (ASIC), a Digital Signal Processing Device (DSPD), a Programmable Logic Device (PLD), a Field Programmable Gate Array (FPGA), a controller, a microcontroller, and a microprocessor. It is understood that the electronic devices for implementing the above processor functions may be other devices, and the embodiments of the present application are not limited in particular.
The Memory may be a volatile Memory (volatile Memory), such as a Random-Access Memory (RAM); or a non-volatile Memory (non-volatile Memory), such as a Read-Only Memory (ROM), a flash Memory (flash Memory), a Hard Disk (HDD), or a Solid-State Drive (SSD); or a combination of the above types of memories and provides instructions and data to the processor.
The embodiment of the application also provides a computer readable storage medium for storing the computer program.
Optionally, the computer-readable storage medium may be applied to any electronic device in the embodiments of the present application, and the computer program enables a computer to execute corresponding processes implemented by a processor in the methods in the embodiments of the present application, which are not described herein again for brevity.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above-described device embodiments are merely illustrative, for example, the division of the unit is only a logical functional division, and there may be other division ways in actual implementation, such as: multiple units or components may be combined, or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the coupling, direct coupling or communication connection between the components shown or discussed may be through some interfaces, and the indirect coupling or communication connection between the devices or units may be electrical, mechanical or other forms.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed on a plurality of network units; some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, all the functional units in the embodiments of the present invention may be integrated into one processing module, or each unit may be separately used as one unit, or two or more units may be integrated into one unit; the integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit. Those of ordinary skill in the art will understand that: all or part of the steps for implementing the method embodiments may be implemented by hardware related to program instructions, and the program may be stored in a computer readable storage medium, and when executed, the program performs the steps including the method embodiments; and the aforementioned storage medium includes: a mobile storage device, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The methods disclosed in the several method embodiments provided in the present application may be combined arbitrarily without conflict to obtain new method embodiments.
Features disclosed in several of the product embodiments provided in the present application may be combined in any combination to yield new product embodiments without conflict.
The features disclosed in the several method or apparatus embodiments provided in the present application may be combined arbitrarily, without conflict, to arrive at new method embodiments or apparatus embodiments.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and all the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the appended claims.
Claims (10)
1. A method of page construction, the method comprising:
building at least two pages based on a configuration file group and a function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
when a target page construction instruction is acquired, determining a target page to be constructed from the at least two pages based on target page identification information in the target page construction instruction;
acquiring a target function module group corresponding to the target page, and modifying at least part of function modules in the target function module group to obtain a function module group modified by the target page;
and reconstructing the target page based on the target configuration file group corresponding to the target page and the modified target function module group to obtain the modified target page.
2. The method according to claim 1, wherein said modifying at least some of the functional modules in the functional module group to obtain the target page modified functional module group comprises:
selecting the at least part of the functional modules needing to be modified from the target functional module group; and modifying at least part of the functional modules to obtain the modified functional module group.
3. The method according to claim 1, wherein said modifying at least some of the functional modules in the functional module group to obtain the target page modified functional module group comprises:
and deleting at least part of the functional modules from the target functional module group to obtain the modified functional module group.
4. The method of claim 1, further comprising:
establishing at least one new functional module for the target page;
and adding the at least one new functional module into the target functional group to obtain the modified functional module group.
5. The method according to any one of claims 1 to 4, wherein the obtaining of the target function module group corresponding to the target page includes:
acquiring a target function module group corresponding to the target page based on the corresponding relation between the at least two pages and the function module group;
or acquiring at least one functional module indication message; determining at least one functional module indicated by the at least one functional module indication information; and utilizing the determined at least one functional module to form the target functional module group.
6. The method according to claim 1, wherein reconstructing the target page based on the target profile group corresponding to the target page and the modified target function module group to obtain a modified target page comprises:
acquiring a target configuration file group corresponding to the target page;
selecting a first configuration file matched with a first functional module from the target configuration file group; wherein, the first functional module is any one functional module in the modified target functional module group;
and constructing a page by using each functional module in the modified target functional module group and the matched configuration file thereof to obtain a modified target page.
7. The method of claim 1,
the configuration file group comprises at least one of the following configuration files: public resources, entry file construction, html construction template and target directory.
8. An apparatus for page construction, the apparatus comprising:
the building unit is used for building at least two pages based on the configuration file group and the function module group corresponding to the at least two pages; the functional module group comprises at least one functional module which is used for constructing functions which can be realized by a corresponding page;
the determining unit is used for determining a target page to be constructed from the at least two pages based on target page identification information in a target page construction instruction when the target page construction instruction is acquired;
the acquisition unit is used for acquiring a target function module group corresponding to the target page;
the modification unit is used for modifying at least part of the functional modules in the target functional module group to obtain a functional module group after the target page is modified;
the constructing unit is further configured to reconstruct the target page based on the target configuration file group corresponding to the target page and the modified target function module group, so as to obtain a modified target page.
9. A page building apparatus, the page building apparatus comprising: a processor and a memory configured to store a computer program capable of running on the processor,
wherein the processor is configured to perform the steps of the method of any one of claims 1 to 7 when running the computer program.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 7.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201911373566.8A CN111158680A (en) | 2019-12-27 | 2019-12-27 | Page construction method, device, equipment and storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201911373566.8A CN111158680A (en) | 2019-12-27 | 2019-12-27 | Page construction method, device, equipment and storage medium |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN111158680A true CN111158680A (en) | 2020-05-15 |
Family
ID=70556951
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201911373566.8A Pending CN111158680A (en) | 2019-12-27 | 2019-12-27 | Page construction method, device, equipment and storage medium |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN111158680A (en) |
Cited By (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111652747A (en) * | 2020-05-29 | 2020-09-11 | 泰康保险集团股份有限公司 | Electronic policy processing method, device, equipment and computer readable storage medium |
| CN111932207A (en) * | 2020-08-06 | 2020-11-13 | 北京金山云网络技术有限公司 | Project data processing method and device, computer equipment and storage medium |
| CN112817632A (en) * | 2021-01-27 | 2021-05-18 | 豆盟(北京)科技股份有限公司 | Interactive page packaging method and device |
| CN114138276A (en) * | 2021-11-18 | 2022-03-04 | 挂号网(杭州)科技有限公司 | Page compiling method and device, electronic equipment and storage medium |
| CN115686678A (en) * | 2022-11-11 | 2023-02-03 | 北京安怀信科技股份有限公司 | Object-based interface information display and interaction definition system and method |
| CN119248267A (en) * | 2024-12-02 | 2025-01-03 | 广东南方智媒科技有限公司 | Customized configuration management method, electronic device and storage medium for Web front-end projects |
Citations (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20020035595A1 (en) * | 2000-09-14 | 2002-03-21 | Yen Hsiang Tsun | Method and system for generating user interfaces |
| CN105095445A (en) * | 2015-07-24 | 2015-11-25 | 北京奇虎科技有限公司 | Page generation method and system |
| CN106980508A (en) * | 2017-04-01 | 2017-07-25 | 百度在线网络技术(北京)有限公司 | Method and apparatus for generating the page |
| US20180367568A1 (en) * | 2017-06-15 | 2018-12-20 | Dell Products L.P. | Visual Policy Configuration and Enforcement for Platform Security |
| CN109542399A (en) * | 2018-10-25 | 2019-03-29 | 深圳市金证科技股份有限公司 | Software development methodology, device, terminal device and computer readable storage medium |
| CN109614568A (en) * | 2018-12-07 | 2019-04-12 | 微梦创科网络科技(中国)有限公司 | A method and device for generating a page |
| CN109857398A (en) * | 2018-11-08 | 2019-06-07 | 深圳壹账通智能科技有限公司 | A kind of generation method of front end page, device, storage medium and computer equipment |
| CN109871210A (en) * | 2019-01-17 | 2019-06-11 | 平安城市建设科技(深圳)有限公司 | Web page element amending method, device, equipment and storage medium |
| CN109960450A (en) * | 2019-04-30 | 2019-07-02 | 上海掌门科技有限公司 | Application startup method and device |
| CN110413272A (en) * | 2019-07-30 | 2019-11-05 | 广州市百果园信息技术有限公司 | Front-end project construction method, device, storage medium and equipment |
-
2019
- 2019-12-27 CN CN201911373566.8A patent/CN111158680A/en active Pending
Patent Citations (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20020035595A1 (en) * | 2000-09-14 | 2002-03-21 | Yen Hsiang Tsun | Method and system for generating user interfaces |
| CN105095445A (en) * | 2015-07-24 | 2015-11-25 | 北京奇虎科技有限公司 | Page generation method and system |
| CN106980508A (en) * | 2017-04-01 | 2017-07-25 | 百度在线网络技术(北京)有限公司 | Method and apparatus for generating the page |
| US20180367568A1 (en) * | 2017-06-15 | 2018-12-20 | Dell Products L.P. | Visual Policy Configuration and Enforcement for Platform Security |
| CN109542399A (en) * | 2018-10-25 | 2019-03-29 | 深圳市金证科技股份有限公司 | Software development methodology, device, terminal device and computer readable storage medium |
| CN109857398A (en) * | 2018-11-08 | 2019-06-07 | 深圳壹账通智能科技有限公司 | A kind of generation method of front end page, device, storage medium and computer equipment |
| CN109614568A (en) * | 2018-12-07 | 2019-04-12 | 微梦创科网络科技(中国)有限公司 | A method and device for generating a page |
| CN109871210A (en) * | 2019-01-17 | 2019-06-11 | 平安城市建设科技(深圳)有限公司 | Web page element amending method, device, equipment and storage medium |
| CN109960450A (en) * | 2019-04-30 | 2019-07-02 | 上海掌门科技有限公司 | Application startup method and device |
| CN110413272A (en) * | 2019-07-30 | 2019-11-05 | 广州市百果园信息技术有限公司 | Front-end project construction method, device, storage medium and equipment |
Cited By (8)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111652747A (en) * | 2020-05-29 | 2020-09-11 | 泰康保险集团股份有限公司 | Electronic policy processing method, device, equipment and computer readable storage medium |
| CN111652747B (en) * | 2020-05-29 | 2023-08-29 | 泰康保险集团股份有限公司 | Electronic policy processing method, device, equipment and computer readable storage medium |
| CN111932207A (en) * | 2020-08-06 | 2020-11-13 | 北京金山云网络技术有限公司 | Project data processing method and device, computer equipment and storage medium |
| CN112817632A (en) * | 2021-01-27 | 2021-05-18 | 豆盟(北京)科技股份有限公司 | Interactive page packaging method and device |
| CN114138276A (en) * | 2021-11-18 | 2022-03-04 | 挂号网(杭州)科技有限公司 | Page compiling method and device, electronic equipment and storage medium |
| CN115686678A (en) * | 2022-11-11 | 2023-02-03 | 北京安怀信科技股份有限公司 | Object-based interface information display and interaction definition system and method |
| CN115686678B (en) * | 2022-11-11 | 2023-08-22 | 北京安怀信科技股份有限公司 | An object-based interface information display and interaction definition system and method |
| CN119248267A (en) * | 2024-12-02 | 2025-01-03 | 广东南方智媒科技有限公司 | Customized configuration management method, electronic device and storage medium for Web front-end projects |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN111158680A (en) | Page construction method, device, equipment and storage medium | |
| CN110147225A (en) | A kind of code generating method, device and computer equipment, storage medium | |
| EP3113020A1 (en) | Data processing device and method for processing serial tasks | |
| CN105630488A (en) | Docker container technology-based continuous integration realizing method | |
| CN117034821B (en) | Regression verification method and medium for chip design front-end simulation verification | |
| CN103646104A (en) | Hard real-time fault diagnosis method and system | |
| CN112631600A (en) | Software construction method and system based on Flutter | |
| CN116185425B (en) | Event flow arrangement method, device, equipment and medium based on node combination | |
| CN116737130B (en) | Method, system, equipment and storage medium for compiling modal-oriented intermediate representation | |
| CN115185539B (en) | Method, device and storage medium for generating executable dynamic link library file | |
| CN111767217A (en) | JS unit test case generation method and device | |
| CN118034660A (en) | Graph compilation method, device and storage medium for large language model fusion operator | |
| Schönberger et al. | Algorithmic support for model transformation in object‐oriented software development | |
| US20250306903A1 (en) | Method and Device for Update of Target File of Automotive Open System Architecture | |
| CN112685040B (en) | Method, device, equipment and storage medium for generating interface file in android system | |
| CN112328241B (en) | Method and device for creating Android library module dependency relationship in application program development | |
| CN120215933A (en) | Processing method, system and related equipment for multiplexing low-code platform components | |
| CN114020604A (en) | Workflow-based automatic testing method and device | |
| CN115933514B (en) | Control method, device, terminal and storage medium based on soft PLC | |
| US20230359547A1 (en) | Targeted Testing for Modular Software Applications | |
| CN117008920A (en) | Engine system, request processing method and device, computer equipment and storage medium | |
| CN114328016A (en) | Data synthesis method, device, equipment and storage medium | |
| CN111638905A (en) | Version number generation method and device, electronic equipment and readable storage medium | |
| CN113391942A (en) | Shell script log printing method and device, electronic equipment and storage medium | |
| CN120562465B (en) | A CGF-oriented typical paradigm behavior model conversion method and device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| RJ01 | Rejection of invention patent application after publication |
Application publication date: 20200515 |
|
| RJ01 | Rejection of invention patent application after publication |